Assignment #1 CSI205 Assigned: 9/15/09 Due: 9/22/09 Assignment: Write a program that computes a payment, total interest charge, and future value of a mortgage based on the amount of the loan (Principal), interest rate, and term. 1. The Mortgage Payment is computed as: Payment=(Principal*r/12.0)/(1-temp) where r = interest rate/100.0 temp = (1.0/pow(x,y)) x = 1.0+r/12.0 and y = term of mortgage in years * 12.0 2. The Future Value of the loan is computed as: Future value = Payment * term of mortgage in years * 12 3. The Interest Charge is computed as: Interest Charge = Future Value - Amount of Loan To complete this assignment, you must query the user for the necessary information IN THE FOLLOWING ORDER: Principal Amount Term of Mortgage in Years Interest Rate Your program needs only to accept one set of values (i.e. only compute for one mortgage) Your program should output the following on seperate lines: Principal, Future Value, Term of Loan in Years, Interest Rate, Interest Charge, and Payment. All dollar figures should print with two places to the right of the decimal point. Notes: -Include Comments in your code and format your program neatly. Remember to include your name and Student ID# in your comments -The pow() method is included in the Math class, which is part of the java.lang package. Therefore, no import statement is needed to use this class. This method is used with the statements Math.pow(x,y) -All variables you use for mathematical computations should be of type double -The name of the file which you save your application into should be named Mortgage.java. (the "M" is uppercase!)