Languages versus their implementations

Python is a programming language. It is nothing more but one large document of text and code examples (a standard) that describes exactly how the language is to behave. You can’t run it, download it, or execute it. That’s it, it’s just text.

The latest edition of it is up on the official Python website as the The Python Language Reference. As Python also consists of a standard library of functions, a document that describes how the modules and their respective functions are to behave is also readily available as The Python Standard Library.

CPython on the other hand is the reference implementation of Python. It is an actual piece of software (written in C) that you can download and execute for platforms that support it. It’s an interpreter that runs code written in Python as described by the ‘Python Language Rererence’, to which it conforms.

You can browse its source code here (or download it as a tarball here), and download it for your respective platform here.

Other implementations of the Python language exist, too. Examples include IronPython, Jython, PyPy, and others. They all conform to the standard to some degree, and they can all execute valid Python code, but they do it in different ways (Jython is an implementation that compiles Python code to Java bytecode and executes it in a JVM).

Another example

C is a programming language. Its standard is published by ISO and ANSI. Again, it is nothing but a large document full of text and code examples, that, again, describes all of the internals of the language as well as how it should behave, in great detail. Unfortunately it is copyrighted and ISO requries that you pay for it (and here’s why), however drafts can be commonly found on the internet.

Here’s the N1570 draft of the C11 standard (it is absolutely massive).

Implementations of the C standard are compilers. Obvious examples include gcc, clang, or MSVC. (gcc isn’t actually a proper implementation of the C standard as it doesn’t supply a C standard library implementation (which is a part of the standard), however it is usually paired with glibc, the GNU C Library). They take C code and compile it to machine code that can then be properly executed.