4
Answers

C# help to find right solution

Alex

Alex

11y
1.2k
1
The program to analyse a housing loan where the user is to enter the amount of the loan, the annual interest rate,and the duration of the loan in whole number of years. If invalid data  has been entered the user should be advise, otherwise use a method to calculate the monthly payment and then display it.

method: private decimal calcMOnthlyPayment(decimal p,doube r,int n)
formula is: payment =p*r/(1-(1+r)^(-n))

where ^ means raised to a power,p is amount of the loan,r is the monthly interest rate, and n is the duration of the loan in month.

The annual interest rate should be a decimal number between 0 and 1and divided by 12.

Thanks for answers for advance..
Answers (4)