Make Math Work

Coins

**Usage:** Coins Quarters, [Dimes, [Nickels, [Pennies]]]

The **Coins** command will show the value of the coins entered. The first number entered is quarters, the second dimes, then nickels and pennies. Numbers progressively to the right can be omitted. For example, the value of two quarters can be found using the command Coins 2. The value of two quarters and three dimes can be found by using the command Coins 2, 3. To find the value of only three dimes, zero must be entered for the quarters by using the command Coins 0, 3.

A graphic representation of the coins is also shown. If more than eleven of any one coin is requested, the diagram will not be drawn, for example, no graphic will be displayed with Coins 2, 12, 3, 1.

Coins 4, 3, 2, 1 displays the value of four quarters, three dimes, two nickels, and one penny.

Coins 3, 0, 0, 2 displays the value of three quarters and two pennies.

Coins 2, 0, 3 displays the value of two quarters and three nickels.

Try It | |||

Enter the number of quarters: | |||

Enter the number of dimes: | |||

Enter the number of nickels: | |||

Enter the number of pennies: | |||