import os os.system("javac lolol.java")# or something....
CMD /K - execute a command then remain import os os.system('cmd /k "Your Command Prompt Command"')
import subprocess subprocess.run(["ls", "-l"])