problem by constrcuting a defining diagram B. Create a solution algorithm using pseudocode C. Desk-check the solution algorithm using two valid test ca

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

In the following problem, you will need to:

A. Define the problem by constrcuting a defining diagram

B. Create a solution algorithm using pseudocode

C. Desk-check the solution algorithm using two valid test cases

3. You require an algorithm to read in three values from a customer's bank
account: the account balance at the beginning of the month, a total of all
withdrawals from the account for the month, and a total of all deposits into the
account during the month. A federal tax charge of 1% is applied to all
transactions made during the month. The program is to calculate the account
balance at the end of the month by (1) subtracting the total withdrawals from
the account balance at the beginning of the month, (2) adding the total
deposits to this new balance, (3) calculating the federal tax (1% of total
transactions - that is, total withdrawals + total deposits), and (4) subtracting
this federal tax from the new balance. After these calculations, print the final
end-of-month balance.
Transcribed Image Text:3. You require an algorithm to read in three values from a customer's bank account: the account balance at the beginning of the month, a total of all withdrawals from the account for the month, and a total of all deposits into the account during the month. A federal tax charge of 1% is applied to all transactions made during the month. The program is to calculate the account balance at the end of the month by (1) subtracting the total withdrawals from the account balance at the beginning of the month, (2) adding the total deposits to this new balance, (3) calculating the federal tax (1% of total transactions - that is, total withdrawals + total deposits), and (4) subtracting this federal tax from the new balance. After these calculations, print the final end-of-month balance.
Expert Solution
Step 1

Summary
In summary, the algorithm reads in the account balance at the beginning of the month, the total withdrawals and total deposits for the month, and calculates the account balance at the end of the month by first subtracting the total withdrawals from the beginning balance, then adding the total deposits to this new balance. Next, the algorithm calculates the federal tax, which is 1% of the total transactions, and deducts it from the gross balance to obtain the final end-of-month balance. The algorithm outputs this end balance.

 

steps

Step by step

Solved in 2 steps with 3 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY