function galileo_test ( )

%*****************************************************************************80
%
%% galileo_test() tests galileo().
%
%  Licensing:
%
%    This code is distributed under the MIT license.
%
%  Modified:
%
%    09 January 2022
%
%  Author:
%
%    John Burkardt
%
  fprintf ( 1, '\n' );
  fprintf ( 1, 'galileo_test():\n' );
  fprintf ( 1, '  galileo() reports the number of ways to make each sum\n' );
  fprintf ( 1, '  from 1 to 18, when three dice are rolled.\n' );

  total = galileo ( );
  n = sum ( total );

  fprintf ( 1, '\n' );
  fprintf ( 1, '  Total  Number of ways   Probability\n' );
  fprintf ( 1, '\n' );
  for s = 1 : 18
    fprintf ( 1, '     %2d     %2d  %g\n', s, total(s), total(s) / n );
  end 

  return
end

