Coding by Hand
Python home

The Python Philosophy

A gym that lets anyone in but hands everybody the same equipment — that is Python. A first-day lifter and an Olympic medalist walk into the same room. The bar weighs the same 45 pounds for both. The plates are the same size. The squat rack does not ask who you are before it opens the pins. That is the design choice that made Python eat the programming world.

Guido van Rossum was working at a lab called CWI in Amsterdam over Christmas 1989, bored and irritated by the language he was stuck using. The language was ABC, built for beginners in a way that fought the beginner the second they wanted more. Rigid. Opinionated about everything. Hard to extend. Over that week Guido wrote a new language that kept ABC's readability and threw out the rigidity. He named it Python after Monty Python's Flying Circus, not the snake. The first public release shipped in February 1991.

A lone researcher in Amsterdam, winter 1989, and the Python timeline that followed.
A lone researcher in Amsterdam, winter 1989, and the Python timeline that followed.

The foundation Guido picked was readability. Ask any working programmer what separates Python from Java or C++ and they will tell you some version of "you can read it." That is not an accident. It is baked into the language the way a gym chooses whether to carpet the platforms or leave them bare wood. Every other choice falls out of it. Indentation is part of the syntax — no braces to argue about. One obvious way to do most things — no committee of six styles for the same loop. Functions and classes read close to English. A person who has never written code can guess what a 10-line Python script does. That is the superpower.

In 2001 Tim Peters, one of the core developers, wrote a short poem that sums up the design. It lives inside Python itself. Once you have Python installed on your machine — which is lesson 6 of this site — you type this into a terminal, and it prints out.

python -c "import this"

The output starts with:

The Zen of Python, by Tim Peters
 
Beautiful is better than ugly.
Explicit is better than implicit.
Simple is better than complex.
Complex is better than complicated.
Flat is better than nested.
Sparse is better than dense.
Readability counts.

Read the list line by line. Every line is a rule the language enforces on itself. "Explicit is better than implicit" means the code tells you what it is doing, not what it might be doing behind your back. "Readability counts" means the people reading your code matter more than the writer's cleverness. These are not suggestions on a poster in the break room. They are the reasons the language looks the way it does.

Python paid a real price for its choices and then paid another to fix its mistakes. In 2008 the core team shipped Python 3, which corrected old sins from Python 2: unicode strings by default, a print function instead of a print statement, integer division that returned the obvious answer. The fixes broke old code. The community spent the next 12 years on a slow, painful migration, with some of the biggest libraries — NumPy, Django — holding both versions together at once. The migration completed in 2020 when Python 2 reached end of life. The pain was the price of admitting the earlier design was wrong.

The Zen of Python, pinned up like a workshop poster.
The Zen of Python, pinned up like a workshop poster.

The payoff was that once the gym was clean, everyone showed up. The scientific stack arrived in waves: SciPy in 2001 for math and engineering, NumPy in 2006 with fast arrays, pandas in 2008 for tables and spreadsheets, scikit-learn in 2010 for classic machine learning. Then the deep learning wave picked Python because the rest of the stack already spoke it — Theano, Keras, TensorFlow, and in 2016 PyTorch, which is now the training framework behind most large AI models. Wall Street picked Python in the same decade for the same reason: the quants wanted a language that let them prototype a trading idea on Monday and ship it by Thursday without hiring a separate team to rewrite it in C++. As of late 2024 Python is the most used language on GitHub, ahead of JavaScript for the first time since the site launched.

Philosophy is cheap. Plenty of languages have readable syntax. Python is the one that sat still long enough, with a patient-enough maintainer, for every serious field to adopt it as its second home. Before you type a line of it, it helps to know what programming itself is — what a machine is doing when it runs the code you are about to write.