The following is due 95% to a post by Rahul Kumar on:
https://tecadmin.net/install-python-3-7-on-ubuntu-linuxmint/
Oddly enough, you will need to go to the exact url above; if you just go to https://tecadmin.net you may find you can’t get here from there, or there from here, or whatever.
In 10 seconds or less: Rahul posted a nearly perfect set of instructions, that you can eventually sort out and make work if you follow the chain of comments and make the adjustments. Though it seems from the comments that not everybody captured the corrections and fixes.
More verbiage after the (hopefully accurate) instructions below – this worked for me, installing on RPi B and copied to a new B+:
sudo apt install build-essential checkinstall
sudo apt install libreadline-gplv2-dev libncursesw5-dev \
libssl-dev libsqlite3-dev tk-dev libgdbm-dev libc6-dev libbz2-dev
sudo apt-get install libffi-dev
cd /usr/src
sudo wget https://www.python.org/ftp/python/3.7.2/Python-3.7.2.tgz
sudo tar xzf Python-3.7.2.tgz
cd Python-3.7.2
sudo ./configure –enable-optimizations
sudo make altinstall
OK. You should now be able to confirm the installed version with the Debian command line command:
python3.7 -V
As of this writing, RPi only has up to version 3.5.3 available – which you can confirm from an upgraded installation with the command “python3 -V”. If you just type “python -V” it will reveal you still have an archaic version 2.7.13 installed – which I consider a disservice to any new user.
I realize that companies have to pick a version and stay with it until there is an overwhelming reason to change but I also believe we are well past that boundary. If I had to make a decision for a major enterprise I would stick with 3.6 for a good while because of the irreplaceable improvement in the format options that came with that version – but that is just one guy’s opinion. On the other hand if you are starting anew why not jump on the train at its current stop.
Part of my motivation was that tkinter did not work in a newly downloaded NOOBS installation and since so much I personally do is built around both tkinter and the format options in 3.6 I decided “in for a penny, in for a pound” and went for the newest version to solve both problems.