Question
Consider for example annuity A, which pays $1,000 per year for 25 years, at a cost of $15,000 today. Now consider annuity B, which pays
Consider for example annuity A, which pays $1,000 per year for 25 years, at a cost of $15,000 today. Now consider annuity B, which pays $1,250 per year for 20 years, also at a cost of $15,000 today. Which is a better investment? One way to compare them is to find the implied rate of return in each case; all other things considered equal, the investment with the higher rate of return is superior.
Write a function annuity_rate(n, pmt, pv) to solve for and return the rate of interest required to amortize the pv in n periods with equal periodic payments of pmt.
Your function should call your pv_annuity(r, n, pmt) function when appropriate, and not re-write this calculation in this function.
Examples:
>>> annuity_rate(25,1000,15000) 0.043884217739105225 >>> annuity_rate(20,1250,15000) 0.054501140117645286
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started