At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.
It sounds like the .py file extension is associated with the Python interpreter, so when you double-click on the files, the window opens, the file executes, and if the file doesn't do something to keep the window open, the window closes. Try opening the .py files from your editor, or launch the editor and drag the file into the editor's window.
i assume you are using windows (as i get it from your problem)... what rsmith6559 pointed out is correct so you have 2 options 1. run the command promt and then navigate to the directory where you have the files and the execute the .py files as >>> python filename.py this will let you see the result of the program you wrote (this problem is due to the fact that in windows your actually need special adjustments to hold the screen otherwise it executes the program and exits) 2. use IDLE to write and run your code.
I'm running windows 7, when I right click a .py file theres an option to edit in IDLE
You said the file you downloaded is a zip file, in this case you need to extract the file inside zip file (i.e you need to unzip it) then you can now access the file extract successfully
That's what I'm saying, right clicking and selecting edit in IDLE allows editing instead of executing the script.
Thanks everyone for your help. I have solved my problem. I also could not open my file from idle. (The zip was unfolded but idle would not open because of its location ....downloads/abc.py) i made the path shorter, and than was able to open from the python GUI. Also there was no Path of python to my command prompt.(typing Python into the command prompt did not work) i found a solution on-line. (folder location of Phython: C:Python25)....control panel/system/advanced tab/evironmental variables/new.....In the var name window I typed PATH, in the variable value I typed %Path%;C:Python 25 To rsmith: I was able to drag the file onto my command prompt only after i did this procedure To harsimran: could not navigate to a python file til I did the above Thanks everyone, I appreciate your help PS my system is XP
why did you not download python 2.7.2??
I didn't read the instructions well. The course software (mit cs 6.00), is not compatible with Python 3.0 and higher. It said i could use 2.5.4 (and the rest of the "2" versions). I"ve updated to 2.7.2 (right now side tracked on a codecademy beginners lesson on Python.