Am 11.05.2011 23:02 schrieb Ian:
On 11/05/2011 20:13, Hans Georg Schaathun wrote:
Lists do not have truth values in the
application domain, and therefore truth values in the
implementation domain is complicated.
Exactly. Its just a convention. If it exists, its true, if if doesn't
its false.
Right. And not only that: Python objects resp. classes not claiming to
have a truth value (__nonzero__), but a length (__len__) are judged by
that concerning their truth value: iff the length is 0, their truth
value is False.
Thomas
--
http://mail.python.org/mailman/listinfo/python-list