Question: Assignment 11A Take your code from Homework 2 (future value) Rewrite it so that the FV calculations are done inside a function that you call
Assignment 11A Take your code from Homework 2 (future value) Rewrite it so that the FV calculations are done inside a function that you call inside your Python code.
Assignment 11B Move the function that you wrote in 11A into a separate file Change your main file so that it imports the new file
This is the code:
pv = float(input("Present value: ")) n = int(input("Number of years: ")) i = float(input("Interest rate: "))
#the procces calculate the FV
FV = (pv * (1+i)** n)
#Output print("FV equals to " + str(FV))
Python to be used. Thanks
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
