What is the difference between these two statements?
if newfile <> oldfile
if newfile != olfile
Gonšalo Rodrigues wrote:
> On Wed, 16 Jul 2003 08:57:33 -0400, hokiegal99
> <(E-Mail Removed)> wrote:
>>that sould be:
>>if newfile <> oldfile
>>if newfile != oldfile
> No difference whatsoever. I believe != is prefered (style guide?)
> though -- and that's the one I always use.
> With my best regards,
> G. Rodrigues
Thank you, that is what I thought. What's the reason for having two
symbols mean the same thing?
hokiegal99 <(E-Mail Removed)> wrote in
> Thank you, that is what I thought. What's the reason for having two
> symbols mean the same thing?
Originally Python only had '<>' for the not-equal comparison. Version 0.9.3
added a bunch of C like syntax, such as C's shifting and masking operators.
It also added C style '==' and '!=' comparison operators. The original '<>'
remains valid for backwards compatibility.