Lesson 1 of 55
PythonInstalling Python and Setting Up Your Environment
20 minutes
Course progress2%
What you'll learn
Keep these ideas in mind as you work through the lesson.
Lesson 1 of 55
Python20 minutes
Keep these ideas in mind as you work through the lesson.
In this lesson we’ll walk through the steps to get Python up and running on Windows, macOS, and Linux. We’ll also cover how to verify your installation and create a virtual environment to keep your project’s dependencies isolated.
brew install python.sudo apt-get install python3 python3-venv on Debian/Ubuntu.import sys
print('Python version:', sys.version)
Or simply run python --version in a terminal.
A virtual environment isolates third‑party packages per project.
# From your project folder
python -m venv .venv
# Activate it (Linux/macOS)
source .venv/bin/activate
# Activate it (Windows)
.\\venv\\Scripts\\activate
Now any pip install will affect only this environment.
Popular choices include VS Code, PyCharm Community, and Sublime Text. VS Code works great with the Python extension for linting, debugging, and IntelliSense.
Once you have Python and a virtual environment set up, you’re ready to start coding!