In article mailman.3674.1248461573.8015.python-l...@python.org,
Terry Reedy tjre...@udel.edu wrote:
Better:if isinstance(x, (int, float, complex)):
I never noticed this before, but it seems odd that the second argument to
isinstance() should be a tuple. Using the normal arguments made
On Fri, 24 Jul 2009 15:03:29 -0400, Roy Smith wrote:
In article mailman.3674.1248461573.8015.python-l...@python.org,
Terry Reedy tjre...@udel.edu wrote:
Better:if isinstance(x, (int, float, complex)):
I never noticed this before, but it seems odd that the second argument
to
Steven D'Aprano wrote:
On Fri, 24 Jul 2009 15:03:29 -0400, Roy Smith wrote:
In article mailman.3674.1248461573.8015.python-l...@python.org,
Terry Reedy tjre...@udel.edu wrote:
Better:if isinstance(x, (int, float, complex)):
I never noticed this before, but it seems odd that the second
Roy Smith r...@panix.com wrote:
In article mailman.3674.1248461573.8015.python-l...@python.org,
Terry Reedy tjre...@udel.edu wrote:
Better:if isinstance(x, (int, float, complex)):
I never noticed this before, but it seems odd that the second argument
to isinstance() should be a
isinstance(x, (int, float, complex))
is certainly very compact, and does what I want. Thanks!
--
View this message in context:
http://www.nabble.com/len%28%29-should-always-return-something-tp24639361p24654347.html
Sent from the Python - python-list mailing list archive at Nabble.com.
--