function i4_to_oct_test ( )

%*****************************************************************************80
%
%% i4_to_oct_test() tests i4_to_oct().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    30 June 2021
%
%  Author:
%
%    John Burkardt
%
  test_num = 3;

  i4_test = [ 21, -32, 1776 ];

  fprintf ( 1, '\n' );
  fprintf ( 1, 'i4_to_oct_test():\n' );
  fprintf ( 1, '  i4_to_oct() converts integer -> octal\n' );
  fprintf ( 1, '\n' );
  fprintf ( 1, '        I4       OCT        I4\n' );
  fprintf ( 1, '\n' );

  for test = 1 : test_num

    i4 = i4_test(test);
    oct = i4_to_oct ( i4 );
    j4 = oct_to_i4 ( oct );

    fprintf ( 1, '  %8d  %8s  %8d\n', i4, oct, j4 );

  end

  return
end
