How do I run a Python script from command line?

Nguyễn Tân

New member
How do I run a Python script from command line?
Answer
To run Python scripts with the python command, you need to open a command-line and type in the word python , or python3 if you have both versions, followed by the path to your script, just like this: $ python3 hello.py Hello World!
 

Tìm kiếm

Back
Top