not in

Mark McEahern marklists at mceahern.com
Mon Jan 21 10:49:01 EST 2002


rihad wrote:
> Why does python introduce new syntax with `x not in s'? Isn't it the
> same as `not (x in s)'? Same for `is not'.

Wow, what a good point!  Yeah, and why do BOTH of these work?

	if 2 + 3 == 5:
		print "true!"

	if 3 + 2 == 5:
		print "true!"

And I thought Python was simple.  That's just too much flexibility.

Sheesh!

// mark




More information about the Python-list mailing list