Explore BrainMass

Explore BrainMass

    Mortgage Calculator in Java: Change Request #2

    Not what you're looking for? Search our solutions OR ask your own Custom question.

    This content was COPIED from BrainMass.com - View the original, and get the already-completed solution here!

    Please help with the following problem involving programming languages.

    Change Request #2
    Requestor: Dwain Hammer - Billings, MT
    Write the program in Java (without a graphical user interface) and have it calculate the payment amount for 3 mortgage loans:

    - 7 year at 5.35%
    - 15 year at 5.5%
    - 30 year at 5.75%

    Use an array for the different loans. Display the mortgage payment amount for each loan.

    © BrainMass Inc. brainmass.com March 6, 2023, 3:52 pm ad1c9bdddf
    https://brainmass.com/computer-science/java/mortgage-calculator-in-java-change-request-2-164876

    Solution Preview

    /*
    * MortgageCalculator.java
    *
    */

    public class MortgageCalculator {
    public static int defaultYears = 30;
    public static float defaultLoanAmount = 200000;
    public static float defaultInterestRate = (float)0.0575;

    private int Years;
    private float LoanAmount;
    private float InterestRate;
    private float MonthlyPayment;

    /** Creates a new instance of MortgageCalculator */

    public MortgageCalculator(int years, float LA, float IR){
    Years = years;
    ...

    Solution Summary

    The following posting helps with a problem involving programming. This solution provides the MortgageCalculator.java program. The code is provided in the solution.

    $2.49

    ADVERTISEMENT