Installation
π Python + π» VS Code Setup Guideβ
Welcome, future Pythonista! π Letβs get you up and running with Python and VS Code in a few fun and easy steps. We'll even test things out with a classic "Hello, World!" π
π§° Step 1: Install Pythonβ
π Download Pythonβ
Go to the official Python website and download the latest version:
π https://www.python.org/downloads/
π οΈ Installation Instructionsβ
- Run the installer.
- β Important: Check the box "Add Python to PATH".
- Click Install Now.
- Wait for the magic to happenβ¦ β¨
β Verify Installationβ
Open a terminal or command prompt and type:
python3 --version
You should see something like:
Python 3.13.0
Awesome! Python is ready to party π
π» Step 2: Install VS Codeβ
π Download VS Codeβ
Grab it from the official site:
π https://code.visualstudio.com/
π οΈ Installation Instructions1β
- Run the installer.
- Keep all default settings.
- Make sure to check:
- β "Add to PATH"
- β "Register Code as an editor for supported file types"
- Click Install.
π Launch VS Codeβ
Open up VS Code and bask in its glory.
π§© Step 3: Install the Python Extension for VS Codeβ
- Open VS Code.
- Go to the Extensions tab on the left sidebar (
Ctrl+Shift+X
). - Search for Python by Microsoft.
- Click Install.
VS Code will now understand your Python code like a wise sensei π§ββοΈ
π Step 4: Create and Run Your First Python Programβ
ποΈ Create a Python Fileβ
- Open a folder in VS Code where you want to save your Python files.
- Click New File and name it
helloworld.py
.
βοΈ Add This Codeβ
print("Hello, Python World! π")
βΆοΈ Run Itβ
- Right-click inside the file.
- Choose Run Python File in Terminal.
Or simply click the green "Play" button in the top right corner.
You should see:
Hello, Python World! π
You're officially coding in Python! π₯
π Try Another Example β Adding Two Numbersβ
num1 = 10
num2 = 20
result = num1 + num2
print("Sum is:", result)
Output:
Sum is: 30
π You Did Itβ
You're all set up and ready to conquer the world with Python and VS Code.
Now go forth and build something amazing! π
Happy coding! ππ