Question: Programing Problem 2 Develop module interest.py with functions calculate_simple_interest , calculate_present_value , and calculate_compound_interest . Each function asks the user for the input required for

Programing

Problem 2

Develop module interest.py with functions calculate_simple_interest, calculate_present_value, and calculate_compound_interest. Each function asks the user for the input required for the formula and returns the calculated value.

s = p * r * t

s = simple interest

p = principal

r = rate

t = term of loan

P= F(1+r)n

P = present_value

F = future_value

rate = annual interest rate

years = number_of_years

A=P(1+rn)nt

A = final amount

P = initial principal balance

r = interest rate

n = number of times interest applied per time period

t = number of time periods elapsed

Write a program that lets the user select which calculation they want to use. Sample input/output might be as follows.

Which calculation do you want to perform?

Enter 1 for future value

Enter 2 for compound interest

Enter 3 for simple interest

Enter 1, 2, or 3: 1

Enter future value: 10000

Enter rate: .05

Enter number of years: 4

Present value $8,227.02

Do you wish to continue? yes/no: yes

Which calculation do you want to perform?

Enter 1 for future value

Enter 2 for compound interest

Enter 3 for simple interest

Enter 1, 2, or 3: 2

Enter initial principle: 10000

Enter interest rate: .05

Enter number of times interest applied: 12

Enter number of time periods: 4

Compound interest $12,208.95

Do you wish to continue? yes/no: yes

Which calculation do you want to perform?

Enter 1 for future value

Enter 2 for compound interest

Enter 3 for simple interest

Enter 1, 2, or 3: 3

Enter principal: 10000

Enter interest rate: .05

Enter term of loan: 4

Simple interest $2,000.00

Do you wish to continue? yes/no: no

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!