f---ing typechecking

Neil Cerutti horpner at yahoo.com
Thu Feb 15 11:37:18 EST 2007


On 2007-02-15, Paul McGuire <ptmcg at austin.rr.com> wrote:
> Since tuples are immutable, I think of them as fixed data objects with
> some simple sequential structure, as opposed to lists which are much
> more dynamically accessible/updateable data containers.  

Me, too. There are plenty of things that aren't strictly a
sequence, but which you sometimes want to iterate over anyhow.
If I had a set of fast, overpriced luxury cars in my garage, I
would sometimes want to do something to each one (like wash
them), even though they really aren't in any sequence.

Dictionary keys are the same sort of thing. Even though they
aren't in any sequence, it's still useful to iterate over them.

-- 
Neil Cerutti



More information about the Python-list mailing list