Even if the development language is changed to python3 in Cloud9, version 2 is displayed in python --version

I used this as a reference.

https://teratail.com/questions/32152

Question

I'm learning Python using Cloud9, but I wanted to change the Python version from 2.7 to 3.x, and even if I changed the Python version to Pytyon3 in Language Support of PROJECT SETTINGS, with Python -V If you check it, it will be displayed as 2.7.6. Please let me know if there are any other necessary steps

Answer

I don't know how to change PROJECT SETTINGS, but if you change it on terminal It was made with the following.

If the python command is which python /usr/bin/python You can see that it is in. ls -l /usr/bin/python You can see that this is a symbolic link. You can use other versions of python by changing the substance of this symbolic link. $ ls -l /usr/bin/python lrwxrwxrwx 1 root root 18 Apr 12 13:43 /usr/bin/python -> /usr/bin/python3.5* $ python -V Python 3.5.1

You can change the symbolic link in the following ways. $ sudo bash $ rm /usr/bin/python $ ln -s /usr/bin/python3.4 /usr/bin/python $ python -V Python 3.4.3

Recommended Posts

Even if the development language is changed to python3 in Cloud9, version 2 is displayed in python --version
What to do if the progress bar is not displayed in tqdm of python
A solution to the problem that the Python version in Conda cannot be changed
Check if the string is a number in python
Check if it is Unix in the scripting language
Check if it is Unix in the scripting language
What to do if Python IntelliSense is not displayed in VS Code on Windows
How to check in Python if one of the elements of a list is in another list
What to do if Python does not switch from the System version in pyenv
I want to initialize if the value is empty (python)
[python] How to check if the Key exists in the dictionary
What to do if the image is not displayed using matplotlib etc. in the Docker container
If you want Python completion in VS Code, Microsoft Python Language Server is the best story
In the python command python points to python3.8
How to get the Python version
Switch the language displayed in Django 1.9
[Introduction to Python] What is the most powerful programming language now?
Delete a particular character in Python if it is the last
How to judge that the cross key is input in Python3
How to use the asterisk (*) in Python. Maybe this is all? ..
[Python] The value written in Openpyxl is displayed in exponential notation (E).
How to update the python version of Cloud Shell on GCP
Change the active version in Pyenv from anaconda to plain Python
What to do when the value type is ambiguous in Python?
[Short note] In matplotlib, nothing is displayed even if I show it → Check the backend setting
What to do if there is a decimal in python json .dumps
Add syntax highlighting for the Kv language to Spyder in the Python IDE
If you want to include awsebcli with CircleCI, specify the python version
Check if the URL exists in Python
What is "mahjong" in the Python library? ??
How to check opencv version in python
How to switch python versions in cloud9
How to use is and == in Python
What is the fastest way to create a reverse dictionary in python?
The date is displayed incorrectly in matplotlib.
I created a script to check if English is entered in the specified position of the JSON file in Python.
[For beginners] Unexpected behavior if "\" is included when setting the path in Python
What to do if abort is displayed when inputting camera video in OpenCV
What to do if a version error occurs in the selenium Chrome driver
What to do if (base) is displayed at the beginning of the Mac terminal
How to use the C library in Python
Introduction to Python Let's prepare the development environment
Check if the characters are similar in Python
What is wheezy in the Docker Python image?
To dynamically replace the next method in python
About the difference between "==" and "is" in python
Draw graphs in Julia ... Leave the graphs to Python
How to specify TLS version in python requests
The trick to write flatten concisely in python
How to get the files in the [Python] folder
I want to display the progress in Python!
Create a python script to check if the link at the specified URL is valid 2
Python --If statement judgment behavior under multiple conditions (even though the order is different)
[Curse of dimensionality] If the number of sensors is changed to ∞, can anomaly be detected?
What to do if the Microsoft Store opens even if you run python on Windows
What to do if you get `No kernel for language python found` in Hydrogen
Create a python script to check if the link at the specified URL is valid
What to do when only the window is displayed and nothing is displayed in pygame Note
What to do if the print command itself causes an error in Maya python
If you get the error "basis matrix is singular to working precision" in GLPK
[Python] Precautions when it does not work even if TimedRotatingFileHandler is set in basicConfig in python2