Contents
By default python on mostly ubuntu, there is python 2. We need to use python3 to run the python files with the latest version.
How do I find my python version Ubuntu?
Four steps to check the Python version on your Ubuntu operating system.
- Open Dash: click the upper left symbol.
- Open terminal: type “terminal”, click on the terminal app.
- Execute command : type python –version or python -V and press enter.
- The Python version appears in the next line right below your command.
How do I make python3 8 default on Ubuntu?
To change Python 3.6. 8 as the default in Ubuntu 18.04 from Python 2.7 you can try the command line tool update-alternatives . Change the path /usr/bin/python3 to your desired python version accordingly.