Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a C# program that simulates a bank. You should be able to deposit money and withdraw money, check the balance, and count savings after

Write a C# program that simulates a bank. You should be able to deposit money and withdraw money, check the balance, and count savings after a certain number of years. This is done via a menu that you have to do with a switch set.

[Deposit

[Socket

[S] aldo

[E nterest rate payment

[End

When calculating interest payment the program should ask for an annual deposit amount, an interest rate and number of years you want to save. The program must then use an iteration (loop) to calculate how many years it takes before the savings target is reached.

An example of how money grows when saving:

If you get a 10% return of SEK 100, then your SEK 100 increases by SEK 10, to SEK 110. Next year, if you get a 10% return again, then your money will increase from SEK 110 to SEK 121. An increase of SEK 11. One krona more than the first year. The second year's increase of SEK 11 is partly due to the basic investment of SEK 100 and partly on the first year's return of SEK 10.

Enter a pseudocode for the switch set in the menu. Also draw flow charts.

Write pseudocode to calculate Interest Payment, ie the part of the program that calculates the balance after a certain number of years with a specific interest rate. Also draw flow charts.

The general description of the program would be as follows:

Declaration of variables and their data type Get input from the user, balance, deposit, withdrawal, deposit / year, interest rate, number_years. Do not forget to initialize a variable balance with a certain value. Check that the entered values are greater than zero using if statements. Printing the menu using the switch set Depending on the user's choice, calculation of balance when depositing, withdrawing or paying interest at saving or printing the current balance. The program ends with a greeting Compile and run the program.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

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

DATABASE Administrator Make A Difference

Authors: Mohciine Elmourabit

1st Edition

B0CGM7XG75, 978-1722657802

More Books

Students also viewed these Databases questions