Assuming you use Windows :)
Open up notepad, write what you need to do in the bat file, save it as a
.bat file
Eg
Open -> Notepade.exe
write -> javac CompileJavaFile.java
write -> java RunJavaFile
SaveAs -> RunCompile.bat (in the directory your java files are in)
A .bat file should have appeared in that directory :) Double click it
for fun and adventure.