Skip to main content
Web Fundamentals: Assignment 1 is due at the end of week 2.
My College
On this page

Setting Up Python

Install Python and check your setup.

This lesson walks through installing Python and running your first program. Replace this with your own content.

Installing Python

Download the installer from python.org/downloads and run it. On the first screen, tick Add python.exe to PATH.

Your first program

Create a file named main.py:

Pythonmain.py
def main():
print("Hello, Python!")
if __name__ == "__main__":
main()

Run it from the same folder:

Terminal window
python3 main.py

The terminal prints Hello, Python!. On Windows, run py main.py instead.

Topics

  • Installing Python
  • Configuring your editor
  • Running your first program

Last updated: