Why = = (and not just =)
Piet van Oostrum
piet at cs.uu.nl
Sun Oct 19 23:10:27 CEST 2003
>>>>> "Joe Green" <someone at microsoft.com> (JG) wrote:
JG> Sorry, I cant help aking stupid questions:
JG> I understand why we need = = in C, but why in Python (or Java),
JG> surely if you write
JG> if a=b: pass # syntax error
JG> it could not possibly mean anything other than what I intended
JG> (which was of course if a = = b:) ?
So what about a = b = c vs. a = b==c?
Piet van Oostrum <piet at cs.uu.nl>
URL: http://www.cs.uu.nl/~piet [PGP]
Private email: P.van.Oostrum at hccnet.nl
More information about the Python-list