DataSmash:
>I'm confused.  Why is it that when I say "while len(list) < 5:", I get
>5 items in my list.

Because the last time when len(list) was < 5, the block of code following
the while executed and did something to the list to give it a length >= 5
(otherwise the block of code would be executed again and it wouldn't have
been the last time).

>        list.append(num)

There you have it.

-- 
René Pijlman

Wat wil jij leren?  http://www.leren.nl
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to