[Python-Dev] "and" and "or" operators in Py3.0

Andrew Koenig ark at acm.org
Thu Sep 22 14:06:36 CEST 2005


> In C, C++, C#, Java, and JavaScript, what do you get when you print the
> result of 3 || 10?

In C and C++, you get 1.  (in c++ the result is actually true, not 1, but
true prints as 1 by default for backward compatibility)





More information about the Python-Dev mailing list