I am not very experienced at Linux but I recently installed Ubuntu 19.10 and I am trying to use Python 3 and the default is Python 2. I spent a lot of time reading how to configure Ubuntu to run Python 3 but I felt to do it. Can anyone please help me? I used these commands but nothing works...
sudo update-alternatives --list python
sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.7
python
always refers to Python2 (in accordance with PEP394). Don't change that behavior in Ubuntu, or you will break things. However,python
(py2) is NOT installed by default in newer releases of Ubuntu anymore anyway. Instead,python3
is installed, and important parts of your system (like apt) rely upon it. Don't change it either. – user535733 Nov 15 '19 at 20:25