Reference no: EM131479872
Instructions: The following programming problem can be solved by a program that performs three basic tasks (Input Data, Process Data, and Output Results) along with selection and repetition coding techniques.
Starting with the program you created in Programming Project 1 and using RAPTOR, design a suitable program to solve this problem.
Problem Statement
"A finance company provides loans for motorcycles at different rates depending on how much the total loan amount is and how many payments will be made on the loan. Using the information in the table below, write a program that will calculate the monthly payment based on user inputs of loan amount and number of monthly payments.
The user will NOT input the percentage rate, as this will be determined by the program code based on user input of loan amount and number of payments. The output will display the loan amount, number of payments, monthly payments and the interest rate of the loan.
Use a loop to allow users to enter as many sets of data as desired. At the end of each loop, ask the user if he or she would like to Exit the program (Y for Yes or N for No). If yes, clear the variables and repeat the input, processing and output loop. If no, exit the program."
Problem Statement
|
Amount of Loan
|
# of Payments
|
Interest Rate Applied
|
$500 - $ 2,500
|
6-12
|
8%
|
13-36
|
10%
|
37-48
|
12%
|
$2,501 - $10,000
|
6-12
|
7%
|
13-36
|
8%
|
37-48
|
6%
|
$10,001 or above
|
6-12
|
5%
|
13-36
|
6%
|
37-48
|
7%
|
If the user enters data that is "out of bounds" (loan amount/number of payments below or above minimum/maximum in table), display an error message explaining the situation to the user and ask for the loan amount or number of payments (whichever one was out of bounds) again. Message Example: "We do not finance loans below $500."
You MUST use Modular Programming techniques by using Sub Modules (Sub Charts in RAPTOR) in your program. Your "main" module should not be very large.