Emile van Sebille wrote:
On 7/16/2009 7:04 AM Unknown said...
On 2009-07-16, Emile van Sebille <em...@fenx.com> wrote:
daysInAdvance = int(inputVar) or 25

I don't get it.  That doesn't work right when inputVar == "0".

Aah, but you didn't get to define right. :) For that particular example 0 is not a valid response.

Emile

When I was talking about such error prone form of boolean operations, I didn't expect to be right so quickly :p Steven explained the truth notion with the Something/Nothing. "0" is Something, 0 would be Nothing. I'm not sure it makes sens anyway. I mean, I could easily argue that the number 0 is something. In the end I wonder if I shouldn't just acknowledge the python mechanism without trying to find any intuitive/natural/obvious logic in it, knowing that sometimes the Truth lies far away from the Evidence.

JM
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to