'python' is not recognized as an internal or external command

Dave Stallberg picture Dave Stallberg · Jul 30, 2013 · Viewed 491.4k times · Source

So I have recently installed Python Version 2.7.5 and I have made a little loop thing with it but the problem is, when I go to cmd and type python testloop.py I get the error:

'python' is not recognized as an internal or external command

I have tried setting the path but no avail.

Here is my path:

C:\Program Files\Python27

As you can see, this is where my Python is installed. I don't know what else to do. Can someone help?

Answer

Asif Iqbal picture Asif Iqbal · Dec 9, 2014

Try "py" instead of "python" from command line:

C:\Users\Cpsa>py
Python 3.4.1 (v3.4.1:c0e311e010fc, May 18 2014, 10:38:22) [MSC v.1600 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>