[Python-Dev] PEP 285: Adding a bool type (original) (raw)
Guido van Rossum guido@python.org
Fri, 05 Apr 2002 11:31:01 -0500
- Previous message: [Python-Dev] PEP 285: Adding a bool type
- Next message: [Python-Dev] Re: PEP 287: reStructuredText Standard Docstring Format
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Stuart> I mean (i and True) or (i or False)
This example might evaluate i twice, which means it's not really a fair comparison.
But the correct form (i and True or False) still performs faster than bool(i). I'm not sure I care though.
--Guido van Rossum (home page: http://www.python.org/~guido/)
- Previous message: [Python-Dev] PEP 285: Adding a bool type
- Next message: [Python-Dev] Re: PEP 287: reStructuredText Standard Docstring Format
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]