How to check what Python version is using?

To check what version of the Python interpreter is using to execute code, you can use the “version_info” command from the “sys” module:

In this example the Python version 3.5.2. is using.