fork download
  1. /* package whatever; // don't place package name! */
  2. import java.io.*;
  3. /* Name of the class has to be "Main" only if the class is public. */
  4. class Ideone
  5. {
  6. public static void main (String[] args) throws java.lang.Exception
  7. {
  8. System.out.println("The Java Math Progrm.");
  9. int a = 60;
  10. int b = 35;
  11. int c = (a -b);
  12. System.out.println("A " + a + " B " + b + " C " + c);
  13. int d = 91;
  14. int e = 13;
  15. int f = (d / e);
  16. System.out.println("D " + d + " E " + e + " F " + f);
  17. }
  18. }
Success #stdin #stdout 0.18s 55928KB
stdin
1
2
10
42
11
stdout
The Java Math Progrm.
A 60 B 35 C 25
D 91 E 13 F 7