Certificate of Deposit

Run Settings
Language Version
Run Command
import java.util.Scanner; class CD { public static void main(String[] args) { int count = 0; double IIA = 0; double AIR = 0; double desiredEV = 0; Scanner putt = new Scanner(System.in); System.out.println("You have been transfered to the certificates of deposit calulator"); System.out.println("Please enter your values"); System.out.println("The following values have been selected"); System.out.println("------------------------------------"); String iIA = putt.nextLine(); System.out.println("Initial Investement: $"+iIA+".00"); IIA = Integer.parseInt(iIA); String aIR = putt.nextLine(); System.out.println("Interest Rate Anually "+aIR+"%"); AIR = Integer.parseInt(aIR); AIR = AIR/100; String dEV = putt.nextLine(); System.out.println("Ending value: $"+dEV+".00"); desiredEV = Integer.parseInt(dEV); formula { IIA = IIA + (IIA*annualIR); count++; }while(IIA<=desiredEV); System.out.println("Amount of years: "+count+" years"); System.out.println("------------------------------------"); System.out.print("The calculator is pleased to serve you!"); } }
Editor Settings
Key bindings
Full width