Friday, July 23, 2021

Python switch version

 https://stackoverflow.com/questions/5087831

This is if you have both the versions installed.

Go to This PC -> Right-click -> Click on Properties -> Advanced System Settings.

You will see the System Properties. From here navigate to the "Advanced" Tab -> Click on Environment Variables.

You will see a top half for the user variables and the bottom half for System variables.

Check the System Variables and double-click on the Path(to edit the Path).

Check for the path of Python(which you wish to run i.e. Python 2.x or 3.x) and move it to the top of the Path list.

Restart the Command Prompt, and now when you check the version of Python, it should correctly display the required version.


Or add both these paths in this order from top-down:


Python 3.8 location: 

\Users\[Your Username]\AppData\Local\Programs\Python\Python38\python.exe

\Users\[Your Username]\AppData\Local\Programs\Python\Python38\Scripts


https://blog.devgenius.io/python-for-beginners-how-to-install-python-3-8-3-for-windows-pc-a84f5d237c19

No comments:

Post a Comment