Python scripts can be executed by passing the script name to the python command or created as executable commands that can run stand-alone. You’ll learn how to create both in this lesson.
When we want to run the script, we can do:
We can also make the script a stand-alone executable:
#! /usr/bin/env python print("Hello World")
chmod +x script.py