程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
您现在的位置: 程式師世界 >> 編程語言 >  >> 更多編程語言 >> Python

Ubuntu16.04 upgrade from native python3.5 to 3.6

編輯:Python

1. upgrade :

Reference resources :https://blog.csdn.net/qq_32216809/article/details/86347926

Ubuntu The built-in version is python2.7 and 3.5

Enter the command

sudo add-apt-repository ppa:jonathonf/python-3.6
  • Enter the command
sudo apt-get update
  • Enter the command
sudo apt-get install python3.6
  • 1 If necessary, press Yes Oh

adjustment Python3 The priority of the , bring 3.6 High priority

sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.5 1
sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.6 2
  • Now the system python The default is Python2, Need to change to Python3
sudo update-alternatives --install /usr/bin/python python /usr/bin/python2 100
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 150
  • Enter again now python The latest 3.6.7 Version of the

  1. 上一篇文章:
  2. 下一篇文章:
Copyright © 程式師世界 All Rights Reserved