For this example we'll pretend we are running "Foo" (substitute your own filename).

Assumption: File is already compiled.


Notes:

  • The command is "java" not "javac"
  • The command argument is the class name (not filename). Thus no file extension.
C:\Work\Scratch>java Foo