Which Python is running this page?
On this page the answer is 3.13. Run the same file on your own computer later and the numbers will be whatever you installed. (3, 10) is a pair of numbers in round brackets: Python compares the first numbers, then the second. if and else choose between two paths (Phase 2).
Python gets a new version every October, and each version is supported for about five years. This course runs Python 3.13 in your browser and marks every newer feature with a badge such as Python 3.10+, so you always know which Python a piece of code needs.
Change the code and press Run (Ctrl+Enter). Predict what will happen first, then break it on purpose and read what changes. Your edits are saved and match the lesson page.
Ready for more? This phase has 5 hands-on exercises with automatic checks.
Practice questions
Write the code in the editor, run it, then open the model answer to compare.
Write a program that prints Modern Python if the running Python is 3.12 or newer and Older Python otherwise. (Copy the if and else shape from the first example in this topic; Phase 2 teaches it.)
Write a program that prints the running version in the form Python 3.13 using sys.version_info.major and sys.version_info.minor.
Put these versions in order from oldest to newest: 3.9, 3.14, 3.10, 3.8.
Explain it without notes
What do the three numbers in Python 3.13.2 mean?
How often is a new Python version released, and how long is each one supported?
Someone's code works on their machine but gives you a SyntaxError on a line with match. What is the most likely cause and how do you confirm it?
What does a badge such as "Python 3.10+" mean in this course?
Expected output
Major version: 3
Minor version: 13
Short form: (3, 13)
This Python has the match statement.