function i4row_neighbors_test ( )

%*****************************************************************************80
%
%% i4row_neighbors_test tests i4row_neighbors.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    05 January 2020
%
%  Author:
%
%    John Burkardt
%
  timestamp ( );
  fprintf ( 1, '\n' );
  fprintf ( 1, 'i4row_neighbors_test:\n' );
  fprintf ( 1, '  Return the immediate neighbors of a grid point.\n' );

  for i = 1 : 5

    c = randi ( [-10,10], 1, 2 );
    i4vec_transpose_print ( 2, c, '  Grid point:' );
    cn = i4row_neighbors ( c );
    fprintf ( 1, '\n' );
    fprintf ( 1, '  Neighbors:\n' );
    fprintf ( 1, '\n' );
    disp ( cn );

  end
%
%  Terminate.
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'i4row_neighbors_test:\n' );
  fprintf ( 1, '  Normal end of execution.\n' );
  timestamp ( );

  return
end

