0

Why its output is showing error plz tell?

public class Myclass { public static void main(String[] args) { double R = 0.07; double P = 30000; double T = 2; double interest = 0; interest = P * R * T / 100; double Compound interest = 0; Compound interest =P * (1 + R / 100 * R / 100); System.out.println("The simple interest is = " + interest); System.out.println(" The Compound interest is = " + Compound interest); } }

29th Dec 2017, 1:59 PM
Lucky
Lucky - avatar
5 odpowiedzi
29th Dec 2017, 2:21 PM
Shamima Yasmin
Shamima Yasmin - avatar
+ 8
Variable names should not contain space. Change the variable name Compound interest to something else (single word)
29th Dec 2017, 2:12 PM
Shamima Yasmin
Shamima Yasmin - avatar
+ 1
now i came to know thanks shamima
29th Dec 2017, 3:08 PM
Lucky
Lucky - avatar
0
plz tell
29th Dec 2017, 1:59 PM
Lucky
Lucky - avatar
0
plz rebuild the code and send me the code again ...
29th Dec 2017, 2:14 PM
Lucky
Lucky - avatar