function r8vec_max_abs_index_test ( )

%*****************************************************************************80
%
%% R8VEC_MAX_ABS_INDEX_TEST tests R8VEC_MAX_ABS_INDEX.
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    05 July 2015
%
%  Author:
%
%    John Burkardt
%
  n = 10;
 
  fprintf ( 1, '\n' );
  fprintf ( 1, 'R8VEC_MAX_ABS_INDEX_TEST\n' );
  fprintf ( 1, '  R8VEC_MAX_ABS_INDEX: index of entry of maximum absolute value;\n' );
 
  r8_lo = - 10.0;
  r8_hi = + 10.0;
  seed = 123456789;

  [ a, seed ] = r8vec_uniform_ab ( n, r8_lo, r8_hi, seed );
 
  r8vec_print ( n, a, '  Input vector:' );

  ival = r8vec_max_abs_index ( n, a );

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Index of entry of maximum absolute value: %d\n', ival );

  return
end
