Question: Complete in C please. In this program, you will design a simple user interface that manages your finances in a bank account. The user is

Complete in C please. In this program, you will design a simpleuser interface that manages your finances in a bank account. The useris given the option to wait and allow interest to accrue inComplete in C please.

In this program, you will design a simple user interface that manages your finances in a bank account. The user is given the option to wait and allow interest to accrue in the bank account for any number of years, or to add funds. The program will need to keep a tally of the funds (in dollars) in the user's bank account, the current year, and the current interest rate. All three values should start at zero. Program Structure Your program should have one main outer loop that runs indefinitely until the user exits the program. At the start of every loop, display the current year, the current funds in the bank account, and the current interest rate. Prompt for a command from the user. The following commands are to be implemented (and must be case-insensitive): 'W': the "wait" command. The program prompts the user for the number of years to wait, then updates the new funds in the bank account and the current year appropriately. o Error condition 1: The value entered is not an integer. Display an error message and clear the input. Then try to read another integer o Error condition 2: the number of years entered is less than 1. Display an error message and try to read another integer T: "the "invest" command. The program prompts the user to enter the number of each type of coin (quarters, dimes, nickels, and pennies) to invest. It calculates the amount in dollars, adds it to the total, then prompts the user for the new interest rate. Having obtained these values, it then allows the total to collect interest for exactly one year before returning to the main prompt. o Error condition 1: any of the values inputted have a bad format. Display an error message, clear the input, and read the line again. o Error condition 2: any coin count is negative: display an error message and prompt for the number of coins again o Error condition 3: the interest rate is

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!