Home

Stef Mientki a écrit :
> hello,
>
> I discovered that boolean evaluation in Python is done "fast"
> (as soon as the condition is ok, the rest of the expression is ignored).
>
> Is this standard behavior or is there a compiler switch to turn it on/off ?

As it was replied, its standard behavior and cannot be modified.

IMHO, if you really need all your expressions to be evaluated, the clean
(most readable) way may be:

a = <first_expression which must be evaluated>
b = <second_expression(x,y,z) which must be evaluated>
if a and b :
...

A+

Laurent.

previous
next

enumerate overflow
Re: Using fractions instead of floats
Dealing with multiple excel sheets
The private-inheritance variant allows Car to override Engine's virtual functions
Re: Checking if elements are empty
monitoring poznań
www.bwin.com
Bóg Biblia Mesjasz
turystyka światowa
Tkaniny dekoracyjne