"in"consistency?
Ben Finney
bignose+hates-spam at benfinney.id.au
Mon Jul 7 17:38:20 EDT 2008
"David C. Ullrich" <dullrich at sprynet.com> writes:
> >>> 'ab' in 'abc'
> True
> >>> [1,2] in [1,2,3]
> False
<URL:http://www.python.org/doc/ref/comparisons.html>
> Is there a reason for the inconsistency?
Probably. The special behaviour of string types was changed in Python
2.3, according to that document.
--
\ “I put contact lenses in my dog's eyes. They had little |
`\ pictures of cats on them. Then I took one out and he ran around |
_o__) in circles.” —Steven Wright |
Ben Finney
More information about the Python-list
mailing list