you can install both python 2 and python 3 in your machine but you can not use both in single code editor in same time. To use both at same time you have to open one IDEs with python 2 and another IDEs with python 3.
How do I install both python2 and python3?
- install Python 2. x (x is any version you need)
- install Python 3. …
- open Command Prompt.
- type py -2. …
- type py -3.
How do I use python3 instead of python2?
If you are using Linux, add the following into into ~/. bashrc alias python=python3 Restart the shell and type python and python3 should start instead of python2. If you’re using Windows then you can use the Python Launcher For Windows.