Lists and Tuples
Greg Ewing (using news.cis.dfn.de)
g2h5dqi002 at sneakemail.com
Sun Dec 7 22:36:05 EST 2003
Douglas Alan wrote:
> mwilson at the-wire.com (Mel Wilson) writes:
>
>> To me, it's a distinction without a difference. Tuples
>>*act* like immutable sequences, and I use them that way. I
>>don't know, though, that I won't get caught some day.
>
> You'll be fine. The only thing you have to watch out for is that some
> rude folks here might call you names.
That would add some spice to Python's error messages...
Python 3.7 (#1, Sep 31 2007, 14:19:37)
[GCC 5.6.7] on slartibartfast
Type "help", "copyright", "credits" or "license" for more information.
>>> t = (1, 3, 77, 654, 8)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
HumiliationError: The programmer is a pink-faced baboon (tuple used where
list would be more appropriate)
--
Greg Ewing, Computer Science Dept,
University of Canterbury,
Christchurch, New Zealand
http://www.cosc.canterbury.ac.nz/~greg
More information about the Python-list
mailing list