Write a c program that allows the user to make some banking


PROGRAMMING ASSIGNMENT #5

Write a C program that allows the user to make some banking transactions. The program should first prompt the user to enter the current balance of his/her bank account (in dollars and cents, not less than zero). The program should then prompt the user to enter the number of withdrawals to make, and then the number of deposits to make. For this assignment, let's set a maximum of 50 deposits and 50 withdrawals, you'll see why as you read on. These will be stored in arrays, which you will be studying for this assignment. One of your program statements should be: float deposit[50], withdrawal[50];

Using a loop, the program should then prompt the user to enter the amount of the first deposit (a positive amount to add to the bank account balance), the amount of the second deposit, the third, & etc., until the number of deposits have been processed Using a second loop, the program should then prompt the user to enter the amount of the first withdrawal (a positive amount to subtract from the bank account balance, if possible), the amount of the second withdrawal, the third, & , etc. until the number of withdrawals have been processed. Once all deposits and withdrawals have been made, the program should output the ending balance.

Solution Preview :

Prepared by a verified Expert
C/C++ Programming: Write a c program that allows the user to make some banking
Reference No:- TGS01712651

Now Priced at $40 (50% Discount)

Recommended (99%)

Rated (4.3/5)