I am out of trial and error again Lists

Rustom Mody rustompmody at gmail.com
Fri Oct 24 19:42:08 CEST 2014

On Friday, October 24, 2014 10:55:44 PM UTC+5:30, Seymore4Head wrote:
> On Fri, 24 Oct 2014 19:18:12 +0200, "Albert Visser" wrote:
> >On Fri, 24 Oct 2014 19:03:47 +0200, Seymore4Head  wrote:
> >
> >>
> >> http://i.imgur.com/DTc5zoL.jpg
> >>
> >> The interpreter.   I don't know how to use that either.
> >>
> >
> >It's what's on the left hand side of your screenshot. You can simply type  
> >Python statements following the >>> prompt and hit enter to examine the  
> >result, instead of pushing F5 to run your code
> I guess I am confusing the Interpreter with the debugger.  Someone
> suggested I use the Interpreter to step through line by line.
> I don't know how to do that.

Dont bother with the debugger just yet.
For most python programmers, sticking a few print statements 
(expressions in python 3) in adroitly is good enough.*

For now best if you concentrate on
1. What are the features of python -- the language
2. What are the standard data types and functions -- the libraries
3. How to use and jump between the two windows of your screenshot most
   effectively. What you should and should not type in each etc

* One neat trick of using the print to debug.
Say you have a line like


and nx is not getting to be what you expect.
Change it to

nx.append("2"); print(nx)

Cleaning up the print after debugging is easier than if you use a
separate line like so


[I think I learnt this trick from Mark Lawrence]

More information about the Python-list mailing list