Artificial Intelligence: post #1852 — TG.ME

In the previous post, we learned what Python is and why it is the most popular programming language for AI. Before writing our first program, we need to set up our development environment.

📖 Phase 1: Programming Fundamentals

📌 Topic 3: Installing Python & VS Code

To start coding in Python, you need two things:

Python – The programming language that will run your code.

Visual Studio Code (VS Code) – A lightweight and powerful code editor where you'll write and manage your programs.

Step 1: Install Python

1. Visit the official Python website.

2. Download the latest stable version for your operating system.

3. Run the installer.

4. Make sure to check "Add Python to PATH" before clicking Install Now.

5. Complete the installation.

Step 2: Verify the Installation

Open Command Prompt (Windows) or Terminal (macOS/Linux) and type:

python --version

or

python3 --version

If Python is installed successfully, you'll see something like:

Python 3.x

Step 3: Install VS Code

1. Download and install Visual Studio Code.

2. Open VS Code after installation.

3. Go to the Extensions tab.

4. Search for Python.

5. Install the official Python extension by Microsoft.

Step 4: Create Your First Python File

• Open VS Code.

• Create a new folder for your project.

• Create a new file named: hello.py

Step 5: Write Your First Python Program

print("Hello, World!")

Step 6: Run the Program

Click the Run button in VS Code or open the terminal and run:

python hello.py

Output:

Hello, World!

Why Use VS Code?

VS Code is one of the most popular code editors because it offers:

Intelligent code suggestions (IntelliSense)

Built-in debugging

Integrated terminal

Git & GitHub support

Extensions for almost every programming language

Lightweight and fast

Common Beginner Mistakes

Forgetting to check "Add Python to PATH" during installation.

Installing Python but not verifying it using the terminal.

Saving the file without the ".py" extension.

Running the wrong Python version when multiple versions are installed.

Key Takeaways

• Install Python before writing any code.

• VS Code is an excellent editor for Python development.

• Always verify your Python installation.

• Your first Python program is traditionally "Hello, World!"

• A proper setup makes learning Python much easier.

➡️ Double Tap ❤️ For More
❤31
August 15, 2026 3.7K 11