<> vs != was Re: A Suggestion for Python Colon Syntax
Bjorn Pettersen
pbjorn at uswest.net
Tue Dec 26 16:33:33 EST 2000
William Djaja Tjokroaminata wrote:
> I personally think != is better than <>, just because not equal is != in
> C/C++ (or Java too? Now I don't remember what is not equal in Java). I
> like Python and I use it as much as I can. However, there isn't
> a single language which is good for everything. I still use C/C++ a lot
> (and also Perl for one-liners and some text processing), and therefore I
> have to switch between the languages quite often. Isn't it great if all
> the languages agree on what not equal should look like? We will get
> syntax error less often and we have to open the reference books less often
> too. Well, I still have to find my Java books to see what not equal is in
> Java.... (sigh....)
Well, then it is clear, we should never use !=, since if it was meant to mean
not equal it would certainly have been spelt !==. != should of course be
changed to the not assingment operator which would work perfectly in e.g.
loops, where nobody sane would want to have an assignment. <> of course,
should be read as either smaller or greater which everyone intuitively knows
means not equal.
this-is-all-the-timbot's-fault-and-I-should-probably-include-a-<wink>-somewhere'ly
y'rs
-- bjorn
More information about the Python-list
mailing list