Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.002 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'python,': 0.02; 'incompatible': 0.07; 'consistency': 0.09; 'expected.': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'undefined': 0.09; 'bug': 0.12; 'buggy': 0.16; 'finney': 0.16; 'imo.': 0.16; 'nan': 0.16; 'rationale': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'types,': 0.16; 'exception': 0.16; 'result.': 0.19; 'header:User-Agent:1': 0.23; 'question': 0.24; 'header:X-Complaints-To:1': 0.27; 'subject:numbers': 0.31; 'subject:other': 0.31; 'writes:': 0.31; 'agreed': 0.32; 'standards': 0.33; "i'd": 0.34; 'case,': 0.35; 'but': 0.35; 'there': 0.35; 'crazy': 0.36; 'should': 0.36; 'being': 0.38; 'ben': 0.38; 'to:addr:python-list': 0.38; 'expect': 0.39; 'to:addr:python.org': 0.39; 'enough': 0.39; 'either': 0.39; 'received:org': 0.40; 'skip:u 10': 0.60; 'dave': 0.60; 'chance': 0.65; 'here': 0.66; 'behavior': 0.77; 'received:125': 0.84; '\xe2\x80\x9cwe': 0.84; 'angel': 0.91 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Ben Finney Subject: Re: Decimals and other numbers Date: Fri, 09 Jan 2015 14:03:50 +1100 References: <54AF405C.6020609@davea.name> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Gmane-NNTP-Posting-Host: jigong.madmonks.org X-Public-Key-ID: 0xAC128405 X-Public-Key-Fingerprint: 517C F14B B2F3 98B0 CB35 4855 B8B2 4C06 AC12 8405 X-Public-Key-URL: http://www.benfinney.id.au/contact/bfinney-pubkey.asc X-Post-From: Ben Finney User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux) Cancel-Lock: sha1:WQAV50s5MD502LDlIP/nHP8SDbA= X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 21 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1420772948 news.xs4all.nl 2910 [2001:888:2000:d::a6]:58025 X-Complaints-To: abuse@xs4all.nl Path: csiph.com!usenet.pasdenom.info!bete-des-vosges.org!feed.ac-versailles.fr!nerim.net!novso.com!newsfeed.xs4all.nl!newsfeed2.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Xref: csiph.com comp.lang.python:83399 Dave Angel writes: > What you don't say is which behavior you actually expected. Since > 0**0 is undefined mathematically, I'd expect either an exception or a > NAN result. Do you think that the ‘int’ and ‘float’ types, which do produce a number result for ‘0 ** 0’, are buggy and should be fixed? I think the inconsistency is unnecessarily confusing. Perhaps the consistency is in standards outside Python, but I think there is cause here either for a change of behaviour or, if ther eis a good rationale for the incompatible behaviours, to document the rationale. In either case, a bug report is warranted IMO. -- \ “We are all agreed that your theory is crazy. The question that | `\ divides us is whether it is crazy enough to have a chance of | _o__) being correct.” —Niels Bohr (to Wolfgang Pauli), 1958 | Ben Finney