Question: Part II: Write a Program Question 1: [25 points] You are asked to write a simple program for an ATM machine. The program should read

Part II: Write a Program Question 1: [25 points]
Part II: Write a Program Question 1: [25 points] You are asked to write a simple program for an ATM machine. The program should read a number w gives as an output how many 100s, 50s, 20s and 10s should be returned by the ATM. When the entered value is negative a "No output" message is displayed. The ATM has always the preference to give the highest possible value. Sample runl: Enter the value of w: 1230 1230 = 12 * 100 + 0 + 50 + 1 + 20 + 1 + 10 + 0 + 1 Sample run2: Enter the value of w: 500 500 = 5 * 100 + 0 + 50 + 0 + 20 + 0 + 10 + 0 + 1 Sample run3: Enter the value of w: 43 43 = 0 * 100+ 0 * 50 + 2 * 20 + 0 + 10 + 3 * 1 Sample run4: Enter the value of w: -3 No output Part II: Write a Program Question 1: [25 points] You are asked to write a simple program for an ATM machine. The program should read a number w gives as an output how many 100s, 50s, 20s and 10s should be returned by the ATM. When the entered value is negative a "No output" message is displayed. The ATM has always the preference to give the highest possible value. Sample runl: Enter the value of w: 1230 1230 = 12 * 100 + 0 + 50 + 1 + 20 + 1 + 10 + 0 + 1 Sample run2: Enter the value of w: 500 500 = 5 * 100 + 0 + 50 + 0 + 20 + 0 + 10 + 0 + 1 Sample run3: Enter the value of w: 43 43 = 0 * 100+ 0 * 50 + 2 * 20 + 0 + 10 + 3 * 1 Sample run4: Enter the value of w: -3 No output

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related General Management Questions!