Why prefer != over <> for Python 3.0?

dewitters at gmail.com dewitters at gmail.com
Sun Mar 30 10:08:34 CEST 2008

On Mar 29, 12:41 pm, Steven D'Aprano <st... at REMOVE-THIS-
cybersource.com.au> wrote:
> Given that <= is a comparison operator, not an assignment, why do you
> jump to the conclusion that != is an assignment? Why don't you argue that
> "x <= y" means "assign the value of x<y to x"?

Yes, you are right, that could be confusing ;).

> Since you jump to an invalid conclusion about !=, the rest of your
> argument fails.

No, you said <= could be confusing, but we're talking about <> here,
and there is no confusion about that :).

More information about the Python-list mailing list