import sys
print(sys.platform)
print(sys.implementation.name)
print(sys.version_info)
print(sys.version)linux
cpython
sys.version_info(major=3, minor=14, micro=3, releaselevel='final', serial=0)
3.14.3 (main, Feb 4 2026, 13:50:59) [GCC 13.3.0]
Python has several different versions all in various states of maintenance
Python 2 is the previous major version
Many Operating Systems have multiple python versions installed by default
However the default meaning of python (the command to run python) is ill-defined
$ python --version
Command 'python' not found, did you mean:
command 'python3' from deb python3
command 'python' from deb python-is-python3Python 3, the new and currently developed major version is usually found under the command python3
On my machine
$ python3 --version
Python 3.12.3Alternative run times like PyPy have their own run commands
I use uv which is a python version manager
To run a uv managed python version my command is
uv run [python3.X]You can inspect the python version at run time using the sys module
linux
cpython
sys.version_info(major=3, minor=14, micro=3, releaselevel='final', serial=0)
3.14.3 (main, Feb 4 2026, 13:50:59) [GCC 13.3.0]
--version or sys to verify