• Go into the "Subtract" sub-directory
  • In your editor (e.g. Notepad++, Notepad, etc) open the file "Subtract.java"
  • Go to "//PROGRAM STARTS HERE"
  • Use the variables "n1", "n2", "result"
  • Get a number from the end user and put the number in the "n1" variable -- see this example
  • Get a number from the end user and put the number in the "n2" variable -- see this example
  • Compute the difference, e.g.
     result = n1 - n2;
  • Show the result -- see this example
  • Don't forget the semi-colons ';' at the end of the lines
  • Compile and Run

Also see this related example
    public void go()
	 {
        //Use "n1", "n2", "result" as variable names
        int n1, n2, result;

        //PROGRAM STARTS HERE
	}