[BangPypers] date range
Srinivas Reddy Thatiparthy
srinivas_thatiparthy at akebonosoft.com
Thu Feb 25 05:13:39 CET 2010
I mean it to the function foo().
Srinivas Reddy Thatiparthy,
From: bangpypers-bounces+srinivas_thatiparthy=akebonosoft.com at python.org on behalf of Vinay Shastry
Sent: Thu 2/25/2010 9:28 AM
To: Bangalore Python Users Group - India
Subject: Re: [BangPypers] date range
On 25 February 2010 09:21, Shashwat Anand <anand.shashwat at gmail.com> wrote:
>> It can be called just once too...
>> >>> def foo():
>> ... print "called"
>> ... return 0
>> >>> 1 < foo() and foo() < 3
> This is because AND operator short-circuits. So when 1 < foo() is false, it
> terminates then and there. Srinivas is correct here.
Yes, I'm just countering:
"It's called TWICE , no matter with or without side effects."
Vinay S Shastry
BangPypers mailing list
BangPypers at python.org
More information about the BangPypers