Check Python Version On Linux -

python3 -m sysconfig

As of late 2024, the newest major release is , which offers significant performance boosts over 3.12. If your system shows an older version, you can usually upgrade via your package manager, such as Ubuntu's APT or Fedora's DNF . check python version on linux

If you run ls -l /usr/bin/python* , you will likely see the history of Python on your system: python3 -m sysconfig As of late 2024, the

This outputs the version number along with the build date and compiler information. the newest major release is

For a cleaner, version-only string, use: import platform print(platform.python_version()) Use code with caution. Copied to clipboard 3. Locating Multiple Installations

python --version