Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Case 3 : maximum monthly payment only If the user has not provided the square footage but has provided the maximum monthly payment, calculate the
Case : maximum monthly payment only
If the user has not provided the square footage but has provided the maximum monthly payment,
calculate the maximum square footage that their monthly payment can afford in the location specified.
You will need to account for the amount of tax owed per month in determining how big a house the
monthly payment allows for. While there is an algebraic solution for this problem, it gets a bit messy
and because of numerical errorsprecision can sometimes provide not accurate results. Instead, we
recommend that you estimate the maximum square footage that the individual can afford using an
approximation method. To do this, follow the algorithm shown below.
Start with an initial estimate for the maximum square footage eg ft
While the maximum square footage has not been found:
o Calculate the estimated home cost, the principal loan amount, the monthly payment
towards the loan, and the monthly payment for the annual taxes.
o If the two monthly payments sum to a value greater than the maximum monthly payment
provided by the user, reduce the maximum square footage by ft and exit the loop;
otherwise, increase the maximum square footage by ft
Calculate the final monthly payments based on the maximum square footage estimated and
report this value to the user.
Report the max monthly payment as shown below. In the starter code, we provide an incomplete string
that you need to fill with the correct formatting for numbers using the example message below in red
In East Lansing, a maximum monthly payment of $ allows the purchase of a house of sq feet for $
assuming a year fixed rate mortgage with a $ down payment at APR.
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