I have been searching but I am so confused. I so appologize if this has been answered before but I have looked and I am even more confused. All I want to do is run an executable file from a python script.
I know to open notepad.exe (for instance) you do the following.
#opens notepad in windows
import os
print os.system('notepad.exe')
but what if I want to run something specific in a directory
How can I effectively run something like this (this is obviously going to fail)
#opens program in windows
import os
print os.system('c:\files\program.exe')
the more I read about it, the more confused I get.
I have been reading about sys.executable as well as surprocess but its confusing me more than helping. Could someone clarify how this can be done? An example, perhaps to run a "program.exe" file?
rliteral flag ...