Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Say I have a program and it updates the total of a bill for each amount paid by customer. I am having problems with having

Say I have a program and it updates the total of a bill for each amount paid by customer. I am having problems with having the total update for each amount subtracted from the previous total amount in a loop (so it never ends and always calculates the new total). What would the code look like for this type of program in a loop?

For example-

Total Bill: 100

Customer enter amount you wish to pay: 20

Total Bill: 80

Customer enter amount you wish to pay: 40

Total Bill: 40

Step by Step Solution

3.45 Rating (158 Votes )

There are 3 Steps involved in it

Step: 1

binbash bill100 stores 100 echo Total Billbill print the Total Bill escapes the character ... blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Investments

Authors: Zvi Bodie, Alex Kane, Alan J. Marcus

9th Edition

73530700, 978-0073530703

More Books

Students also viewed these Accounting questions

Question

What new age designation has been created and validated for Cognac

Answered: 1 week ago