63

The current version of python I've now which is installed by default with Ubuntu is 2.7rc1 ,
Is it possible to update it officially to the latest version (3.7.1) ?

Thank You .

  • 3
    Python 3.x is contained in the package called "python3". Currently, it looks like it is version 3.6.5. You can have this package and Python 2 co-existing. – Ray Oct 24 '18 at 07:53
  • 1
    What are the results of python3 -V ? They should show that you already have Python 3.6.6 installed in 18.04. – karel Oct 24 '18 at 07:54
  • @Ray I think you should change your comment to an answer to the question – Katu Oct 24 '18 at 08:18
  • Thanks for your attention, I'm a new Ubuntu user, Can you please explain in detail what should I exactly do ? – Ahmed Ashraf Oct 24 '18 at 08:34
  • 1
    You should read the duplicate question link. Asking us to "explain in detail" something that we have already explained in detail seems a bit...um.... – user535733 Oct 24 '18 at 12:43
  • 1
    @AhmedAshraf I hope what I said below helps. But, if you're a new Ubuntu user then I don't suggest you dive into the latest Python. I think for your needs, any Python 3.x will do. If you reach a stage where you're more familiar with Ubuntu and the latest version in the repository isn't good enough for you, then you can consider the latest release. I presume when you reach that stage, you are purposely after features in 3.7.1 that isn't in 3.6.5 . If you don't know (or care) about the difference, then below should help you. – Ray Oct 24 '18 at 16:47
  • @karel It is possible that someone does not have Python 3 installed. Unlikely but possible. But I added information about locating the Python 3 executable in my answer. Thanks! – Ray Oct 24 '18 at 16:48
  • @user535733 I'm sorry for this, I already read the duplicate question and there was some terms I didn't understand like ( apt-get, source tar ball, pseudo package, PPA , ... etc ), But I followed the instructions in the answer below and everything is fine now, Thank you :) – Ahmed Ashraf Oct 27 '18 at 06:35
  • @AhmedAshraf You're welcome! Unfortunately, I wrote a slightly longer reply in response to your query for more information, but it got deleted by moderators. But I'm glad you were able to get the information you needed! – Ray Oct 28 '18 at 10:52

1 Answers1

68

Outdated:

Python 3.7.1 is still in maintenance version. It is only available for download to Windows and macOS users. Once the stable version is released, then it is made available in Linux repositories. For Windows and Mac users visit this python.org URL.

Currently (2022):

For Linux users: you can download the 3.11.0 version from the terminal

sudo apt-get update && sudo apt-get upgrade
sudo apt-get install python3.11

Check the most recent Python version available here: https://www.python.org/downloads/