how to check python version in linux code example
Example 1: how to check python version on terminal
python3 --version # This is to check the python 3 version on mac terminal
Example 2: get python version in code
import platform
print(platform.python_version())
Example 3: check python version kali linux
$ python2 --version