David C. Ullrich wrote:
> Oh, of course that's a good thing - changing "in" for lists
> to give True there would be awful. I was wondering why it
> _does_ work that way for strings.
>
> Maybe the answer is "because it can" - for strings the sort
> of possible problem you point out can't come up.
I think that's it. When people realized how handy
small_string in big_string
would be, they expanded the string behaviour. Python is a pragmatic
language.
Cheers, Mel.
--
http://mail.python.org/mailman/listinfo/python-list