Before we can start giving instructions to the computer, we first need to set up our “coding workshop” or environment. Don’t worry, you only have to do this once!
We need two main tools to start our coding adventure.
- Python Interpreter: This is like a “translator.” It takes our Python code (which we can read) and translates it into a language the computer can understand.
- IDE (Integrated Development Environment): This is a fancy name for a smart text editor made for coding. It helps us by coloring our code and spotting mistakes. We will use Visual Studio Code (VS Code), one of the most popular ones!
Follow these steps to get your computer ready.
- Go to the official Python website: python.org.
- Click on the “Downloads” section. The website should automatically show you the best version for your computer.
- Click the big yellow button to download the installer file.
- Open the file you just downloaded.
- ** VERY IMPORTANT! ** On the first window that pops up, check the box at the bottom that says
Add Python.exe to PATH
. This step is super important! - After checking the box, click
Install Now
and wait for it to finish.
- Go to the official Visual Studio Code website: code.visualstudio.com.
- The website will show a big blue button to download it. Click it!
- Open the downloaded file and follow the instructions. Just clicking “Next” through all the steps is perfectly fine.
Now, let’s teach our smart notepad how to understand Python.
- Open the VS Code application.
- On the left side, there is a bar with icons. Find the one that looks like four squares stacked together. This is the Extensions marketplace.
- In the search bar at the top, type
Python
. - Look for the extension named “Python” from Microsoft. It will be the first and most popular one.
- Click the blue
Install
button next to it.