Normally we have Python 2.* version installed in both Macbook or Ubuntu. Each and every time writing Python3 on every command python uses becomes difficult. So, we can symlink python with python3 in following way:

1. See all python3 versions by giving this command: ls -l /usr/local/bin/python*

/usr/local/bin/python -> /usr/local/bin/python3.9
/usr/local/bin/python3 -> ../../../Library/Frameworks/Python.framework/Versions/3.9/bin/python3
/usr/local/bin/python3-config -> ../../../Library/Frameworks/Python.framework/Versions/3.9/bin/python3-config
/usr/local/bin/python3.9 -> ../../../Library/Frameworks/Python.framework/Versions/3.9/bin/python3.9
/usr/local/bin/python3.9-config -> ../../../Library/Frameworks/Python.framework/Versions/3.9/bin/python3.9-config

 

2. Now make a Symlink to regular python with python3 : ln -s -f /usr/local/bin/python3.9 /usr/local/bin/python

3. Restart your terminal. Now your default Python 2.* has been changed to Python3.9 : python --version