
You can see I am executing simple Python code from the command prompt. So how can you do this. For this you have to set path to use python in your command prompt.
If you are on Window, you need to go to This PC. Right click on it and then choose Properties. Then Advanced System Settings. A box will appear. Then Click on Environment Variables then double click on path and then click "New".
You will need to add following two paths.


After adding those two paths then you can come back to Command Prompt, and then type python and carry out any programming task related to python.