[Tutor] Confused about lists...
Danny Yoo
dyoo@hkn.eecs.berkeley.edu
Fri, 23 Feb 2001 17:00:04 -0800 (PST)
On Fri, 23 Feb 2001, Chris Watson wrote:
> I'm about to try bob's example. And see if string.split(i)... work. I
> still would like to know why it's ignoring my if i[4] line though and
> counting each whole line twice. hrmm. I really appreciate the
> explanation of things so far. I should of used better counter names
> :-) It does make things much easier to know whats going on.
It's not quite a matter of ignoring that line; it's more a matter of the
test within:
if i[4] == 'open-sytems': ...
always failing. If it helps, try putting the line:
print 'Here's what i[4] contains:', i[4]
right before your if-statement, and you'll see something peculiar. *grin*