$24
Change Calculator: 50 points
This program will ask the user for the number of quarters, dimes, nickels, and pennies s/he has and then compute the total value. The total value of the change should be shown as the number of dollars (i.e., a whole number) and then a separate number of cents (also as a whole number). The assignment parameters are:
Develop the money calculating program discussed below using a command line interface, where the class file includes a “main” method to launch the program, imports for required external packages, uses global and local variables where appropriate, and has additional method calls for processing.
The program should use at least one method beyond main: to obtain and validate the input values for each coin type (specifically, the coin counts must be non-negative values)
Include a loop in the process so that the user may enter different sets of coins (i.e., be able to run the calculation multiple times)
A sample run might look as follows:
Welcome to the Change Calculator!
Do you have change (Y/N)? Y
How many quarters do you have? -1
You must enter a non-negative integer. Please try again.
How many quarters do you have? 3
How many dimes do you have? 2
How many nickels do you have? 2
How many pennies do you have? 4
You have a total of 109 cents, which is 1 dollar(s) and 9 cent(s).
Do you have more change (Y/N)? N
Thanks for using the Change Calculator!
Develop the program inside the Netbeans IDE, calling your program CalcChange.java. When finished, zip the entire Netbeans project (from top-level folder down) and submit the zip file through the blackboard assignment link (steps will be demonstrated in class).
Part B:
Add half-dollars to the process. In other words, an additional question ‘How many half-dollars do you have?’ should be asked during each run and then included in the total value calculation.
Extra Credit (5 points):
Code according to posted pseudo-code using coinTotal() method. This varies from the way we built the program in the class (and on the recording).