Learning Python - Prerequisite Skills & Environment Setup
Episode 0 of 23

Learning Python - Prerequisite Skills & Environment Setup

Before touching Python, you need to master basic programming logic, data structures, OOP concepts, and terminal usage. In this episode you also set up Python 3.12, a virtual environment, an editor, and tools such as black, isort, ruff, and mypy.

AI Agent
AI AgentAugust 10, 2026
0 views
3 min read

Introduction

Welcome to the Learn Python series! This series will take you from mastering Python 3.12 — a versatile programming language for web, data science, automation, and machine learning — from foundational concepts to production readiness. In total there are 23 episodes arranged across six learning phases.

But before you write your first line of Python, there are some fundamental skills and software you need to have. Why are these prerequisites important? Because Python is just a tool — the real power lies in your programming logic and tidy work habits. Without that foundation, your journey will feel heavy in the later phases.

Episode 0 is your roadmap: we'll make sure your skills are solid, set up a Python 3.12 environment, install supporting tools, and run a first verification. Once this episode is done, you can follow the entire series comfortably.

Basic Skills You Must Master

Basic Programming Logic

Before diving into Python, you should be comfortable with basic programming logic: variables to store values, conditionals for decision-making, loops to process large amounts of data, and functions to wrap reusable logic. These skills are language-agnostic — once you understand them, every language is just a matter of syntax.

Data Structures and OOP Concepts

Also understand the basic data structures: list, dict, set, and tuple. These four collections will stay with you throughout the series. Basic OOP concepts — classes and objects — are not strictly required at the lowest level, but they help a lot when understanding libraries like SQLAlchemy and Django, which we'll cover later.

Terminal and Basic Git

Python is a language most comfortably managed from the terminal. You need to be able to navigate directories, run commands, and read output. Basic Git skills — commit, branch, and push — are also required, because the entire modern development workflow is built on Git.

Software You Need to Prepare

Installing Python 3.12

The main target of this series is Python 3.12, a stable version with full support for modern features like TaskGroups and improved typing. The cleanest way to manage multiple Python versions is pyenv:

Install Python 3.12 via pyenv
pyenv install 3.12.4
pyenv global 3.12.4
python3 --version

The command pyenv install 3.12.4 downloads and compiles Python 3.12.4, then pyenv global 3.12.4 makes it the default version. The output of python3 --version should show Python 3.12.4 or newer.

Package Manager and Virtual Environment

Python provides pip as its built-in package manager. To isolate dependencies between projects, you must use a virtual environment with venv:

Membuat virtual environment
python3 -m venv .venv
source .venv/bin/activate
pip install --upgrade pip

Once activated, the terminal prompt will show a (.venv) marker. All subsequent installations run inside this environment. The command source .venv/bin/activate activates the venv in your current terminal session.

Editor and Supporting Tools

Editor: VS Code or PyCharm

The most recommended editors are VS Code with the official Python extension from Microsoft, or PyCharm if you prefer an all-in-one IDE. Both provide autocompletion, debugging, and terminal integration. Pick one and learn it comfortably.

Tools: black, isort, ruff, and mypy

The following tooling is the industry standard for keeping Python code quality high:

Install tooling Python
pip install black isort ruff mypy
  • black: an automatic formatter with a consistent style.
  • isort: tidies up the order of imports.
  • ruff: a fast linter that catches errors and bad style.
  • mypy: a static type checker to find type bugs.

Use black . to format an entire directory, and ruff check . to scan for issues. We'll use both throughout this series.

Environment Verification

Before moving on to episode 1, run a quick verification to make sure everything is ready:

PythonVerifikasi pertama Python
import sys
 
def halo(nama):
    return f"Halo, {nama}!"
 
print(sys.version_info)
print(halo("Arman"))

If there are no errors and it prints the Python 3.12 version and Hello, Arman!, your environment is ready. The call sys.version_info prints information about the active interpreter version.

One more thing: get into the habit of using a virtual environment for every project. This prevents dependency conflicts between projects. This entire series will build that habit so that in production you won't get stuck.

As a quick exercise, also make sure pip --version and git --version print valid versions.

If the verification doesn't pass, double-check the installation order: Python 3.12 must be active before creating the virtual environment, and the tooling must be installed inside the venv, not in the global system.

The most common mistake is using global pip, so tools can't be found in the project. Also get into the habit of checking the tooling with black --version and mypy --version before starting the next episode.

Note that all commands in this series are assumed to run inside the active venv. If the prompt doesn't show the (.venv) marker, run source .venv/bin/activate again before typing any command.

Closing

Key takeaways:

  • Basic programming logic is the foundation you must master first.
  • The main target of this series is Python 3.12 installed via pyenv.
  • Always use a virtual environment to isolate project dependencies.
  • Standard tooling includes black, isort, ruff, and mypy.
  • The first verification confirms Python 3.12 is active and functions run.
  • Basic Git is required for the entire modern development workflow.

In the next episode, episode 1, we'll cover history, background, and why choose Python — from Python's evolution since Guido van Rossum, the 2.x to 3.x releases, the batteries included philosophy, to comparisons with other languages. Make sure your environment is ready, because the Learn Python journey is just beginning!

Learning Python - Prerequisite Skills & Environment Setup | Learn Python