Installing Python: Linux

Installation is a slightly different process for every operating system. This lesson is a guide for installing Python on Linux. You can move on to the next lesson if this isn’t relevant to you.

Python in Linux

Many Linux distributions come with a pre-installed version of Python. Older distributions can have Python 2.7, whereas the newer ones may come equipped with the latest version. However, this is not a guarantee. Below, we’ll highlight the different approaches for ensuring that our Linux machine has the latest Python installed. For simplicity, we’ll show the process for Ubuntu.

Checking the version

The first step should always be to check if a version of Python and/or Python3 is already installed. For this, you simply have to go to the terminal and enter the following commands:

Python 2.x

Get hands-on with 1400+ tech skills courses.