Results 1 to 2 of 2

Thread: Java code for mortgage calculator

  1. #1
    BakerJones is offline Senior Member
    Join Date
    Dec 2009
    Posts
    244
    Rep Power
    3

    Default Java code for mortgage calculator

    I'm having problem with this java code, I am write a code for mortgage calculator but it gives lots of error. Kindly provide me the correct logical solution to resolve the above issue. Any help would be highly appreciated.

  2. #2
    AdamsClark is offline Senior Member
    Join Date
    Dec 2009
    Posts
    247
    Rep Power
    3

    Default

    Refer following code for mortgage calculator:

    Code:
    import java.io.*;
    import java.util.Date;
    import java.text.DecimalFormat;
    
    public class Mortgage
    {
    public static void main(String[] args);
    {
    Date currentDate = new Date();
    //Date constructor
    DecimalFormat decimalPlaces=new DecimalFormat("0.00");
    
    //declaring variables
    final double PRINCIPAL = 200000;
    final double INTEREST = .0575;
    final double TERM = 12*30;
    
    //declaring variables
    
    final double MONTHLY = (((PRINCIPLE*(INTEREST/12))/(1-Math (1+(INTEREST/12))-(TERM)))
    
    //displaying variables
    System.out.println("tt" + currentDate);
    System.out.println("ttPrinciple or Loan Amount: " + PRINCIPLE);
    System.out.println("ttInterest Rate: " + INTEREST);
    System.out.println("ttThe Term of Loan (in months): " + TERM);
    System.out.println("ttThe Monthly Payment is: " + MONTHLY);
    System.out.println(decimalPlaces.format(MONTHLY));
    }
    }

Similar Threads

  1. Google: external developers Java code stolen
    By Annalina Blasius in forum Latest Hardware News
    Replies: 0
    Last Post: 11-13-2010, 08:14 AM
  2. Calculator
    By Israel Stevens in forum Download Tools and Softwares
    Replies: 0
    Last Post: 11-04-2010, 10:29 PM
  3. Free Mortgage Payment Calculator
    By Bratton Clovelly in forum Download Tools and Softwares
    Replies: 0
    Last Post: 08-10-2010, 07:41 PM
  4. Java code palindrome number
    By AllenBrown in forum Programming
    Replies: 2
    Last Post: 06-14-2010, 02:18 PM
  5. Java code to run batch file
    By RodríguezBrown in forum Programming
    Replies: 3
    Last Post: 03-31-2010, 03:53 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
SEO by SubmitEdge

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48