Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Enter loan amount: 100000 // sample run 1 Enter rate: 6 Enter number years: 30 The monthly payment is: $599.55 Enter loan amount: 10000 //
Enter loan amount: 100000 // sample run 1 Enter rate: 6 Enter number years: 30 The monthly payment is: $599.55 Enter loan amount: 10000 // sample run 2 Enter rate: 4.5 Enter number years: 3 The monthly payment is: $297.47
- This assignment is comprised of creating a program which will calculate a monthly amoritzed amount (e.g. a house mortgage). The behavior and layout of this program should be as in the example below. Total points for this assignment will be 100 points. This assignment is due on or before Thu, Feb 20. All objects and techniques necessary for this assignment have been (or will be) covered in class.The program should look and function as follows:
- The formula to use for this assignment should/must be as follows:
- You must set the names of all objects/variables included in your program to have meaningful names with correct naming conventions.
- You should refer to the programming guidelines and follow all guidelines presented there. Failure to adhere to any of the assignment specifications/programming guidelines will result in loss of points.
- Make sure to keep a copy of the source code that you turn in.
- Please feel free to ask questions/send e-mail if any items require clarification.
Hints & Updates: (updated Mon, Oct 24th)
- Be sure to adhere to the formula listed above. Deviating from this will most likely result in erroreous results.
- You may NOT use any built in calculating functions (other than Math.pow()), use the formula presented in class
- I suggest using data type of double for this assignment.
- To get input, you will need to use the Scanner class as mentioned in the text as well as in the classroom example. You must use the .nextLine and .parseDouble methods as discussed in class (see notes).
- Make sure you modify the input values for Rate and Years as specified in class.
- You must format the output nicely, either using printf (and %.2f%n) or using the NumberFormat.getCurrencyInstance() method (suggested).
months (1 + rate) monthly payment = rate x amount x months ((1 + rate) -1
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