Why prefer != over <> for Python 3.0?

Michael Wieher michael.wieher at gmail.com
Sat Mar 29 15:24:01 EDT 2008


to me it seems simple.

C uses !=

why does C use != .... because its kind of hard to type the "equal with a
slash"

so if python is supposed to be a simple and easy to use language, use the
simple and easy to understand, standard 'not-equal' operator... Idk, maybe
there's more to it but simple is as simple does, sir

2008/3/29 Lie <Lie.1296 at gmail.com>:

> On Mar 30, 1:24 am, Duncan Booth <duncan.bo... at invalid.invalid> wrote:
> > Lie <Lie.1... at gmail.com> wrote:
> > > You're forcing your argument too much, both != and <> are NOT standard
> > > mathematics operators -- the standard not-equal operator is >< -- and
> > > I can assure you that both != and <> won't be comprehensible to non-
> > > programmers.
> >
> > My maths may be a bit rusty, but I always thought that the standard not-
> > equal operator was like an = sign but with a diagonal slash through it
> as
> > displayed when you do:
> >
> >    print u'\u2260'
>
> Ah yes, that is also used (I completely forgot about that one, my
> math's aren't that sharp anymore) and I think it's used more
> frequently than ><. Some books use >< while most use ≠, but my
> argument was that no math book use != or <> (except in math for
> programmers).
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20080329/5640c30e/attachment-0001.html>


More information about the Python-list mailing list