Solve the problem of unable to locate package python3.6 when upgrading from python3.5 to python3.6 in ubantu16.04

error as follows:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package python3.6
E: Couldn't find any package by glob 'python3.6'
E: Couldn't find any package by regex 'python3.6'

The ppa used by

is the old version:

sudo add-apt-repository ppa:jonathonf/python-3.6

needs to update ppa:

sudo add-apt-repository ppa:deadsnakes/ppa

and then system update:

sudo apt-get update

Finally, python3.6

is installed

sudo apt-get install python3.6

Read More: