Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Draw the flowchart for a program that will dispense money from an ATM machine. Continue to request a withdrawal amount from the user until they
Draw the flowchart for a program that will dispense money from an ATM machine. Continue to request a withdrawal amount from the user until they enter -999. If the amount entered is not evenly divisible by twenty, output the message "You must enter multiples of twenty only" otherwise calculate and output the number of twenty dollar bills you will be dispensing. Hint: to determine whether a number is evenly divisible by twenty, use the modulus operator. This operator is used to find the remainder after the division of a number by another number. For example, The!-notation means "not equal" E.g., X! 5 means that X is not equal to 5 The list of the steps is as follows: a. Set the initial value for the amount of money, X-0 b. Ask the amount of money that the person wants to withdraw. c. If X-999, print "Thank you for using our service." End the process. Else If (X mod 20! 0), print "You must enter multiples of twenty only" jump to Step a. Else The-number-of-bill = X divide 20 print " You will receive" +the-number-of-bill " twenty dollar bills" jump to Step a
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started