Write a program that calculates the different ways to make change for n cents, using quarters (25 ¢), dimes (10 ¢), nickels (5 ¢), and pennies (1 ¢). The value for n will be given as a command-line parameter. The program should show the number of ways, as well as a list of the combinations of coins.
Example:
$ java MakeChange 6
2 ways:
0 quarters, 0 dimes, 1 nickel, 1 penny
0 quarters, 0 dimes, 0 nickels, 6 pennies