"javac <FILE NAME>" (unsurprisingly, stands for "java compile"), will compile your java source code in to a .java file, that can be run with the "java <FILE NAME>" command.
Make sure that your command prompt is set to the right destination when you run these commands, using "cd <DESTINATION>", otherwise they may be unable to find them in the incorrect destination.