install python3.9 on ubuntu 18.04 20.04

More Less
2 min readFeb 6, 2023

Installing Python 3.9 on Ubuntu with apt is a relatively straightforward process and will only take a few minutes:

  1. Start by updating the packages list and installing the prerequisites:
sudo apt update
sudo apt install software-properties-common

2. Next, add the deadsnakes PPA to your sources list:

sudo add-apt-repository ppa:deadsnakes/ppa

When prompted press Enter to continue:

Press [ENTER] to continue or Ctrl-c to cancel adding it.

--

--