[Tutor] Recommendations for best tool to write/run Python

Peter Otten __peter__ at web.de
Thu Mar 3 04:25:27 EST 2016


Lisa Hasler Waters wrote:

> I am new to Python, as are my middle school students. We are using Python
> 3.5.1 IDLE to write and run our (simple) code. However, this tool does not
> seem to be the best way to write longer code or to be able to re-edit code
> that has been saved/closed/reopened.

Hi Lisa!

When Idle opens it shows a window called Shell. That window is meant for 
experiments with existing modules or as a kind of calculator. It is not for 
writing scripts. If you want to write a script go to File->New File in the 
menu and use the window that pops up to write your code. Once you're 
satisfied and want to try the script go to Run->Run Module (or hit F5). 

If you didn't save the script before you will be asked to do that now.
Once you have saved the script Idle tries to execute it.

If there is a syntax error the error is marked and you can fix it.

When there are no more syntax errors the script will run, and if it prints 
anything the output will be shown in the Shell window mentioned above.

Let's say you're done and close Idle for now. The next time you open it you 
can pick the files you worked with recently from the list shown in the menu 
under File->Recent Files.

Did you work with Idle that way? What are your actual complaints?




More information about the Tutor mailing list