Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #83485

Re: Decimals and other numbers

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!us.feeder.erje.net!news2.arglkargh.de!news.swapon.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From Gregory Ewing <greg.ewing@canterbury.ac.nz>
Newsgroups comp.lang.python
Subject Re: Decimals and other numbers
Date Sat, 10 Jan 2015 16:05:52 +1300
Lines 25
Message-ID <chbj8eF76b8U1@mid.individual.net> (permalink)
References <CABicbJK-5izGtet8BsS1Yqx+6AHMX7gLU4zYjjt5jULJXNVipA@mail.gmail.com> <54AF405C.6020609@davea.name> <mailman.17501.1420772593.18130.python-list@python.org> <54af9612$0$12995$c3e8da3$5496439d@news.astraweb.com>
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding 7bit
X-Trace individual.net dc6Qsqv/ajoLnHLrbAUj/QbVfRNKEF3lG1Yal1yqvLianC7bDn
Cancel-Lock sha1:qRqh0jHDw+7AWtWNWzLWdgv5g58=
User-Agent Mozilla Thunderbird 1.0.5 (Macintosh/20050711)
X-Accept-Language en-us, en
In-Reply-To <54af9612$0$12995$c3e8da3$5496439d@news.astraweb.com>
Xref csiph.com comp.lang.python:83485

Show key headers only | View raw


Steven D'Aprano wrote:
> Arguably, *integer* 0**0 could be zero, on the basis that you can't take
> limits of integer-valued quantities, and zero times itself zero times
> surely has to be zero.

It's far from clear what *anything* multiplied by
itself zero times should be.

A better way of thinking about what x**n for integer
n means is this: Start with 1, and multiply it by
x n times. The result of this is clearly 1 when n
is 0, regardless of the value of x.

 > 5**4 = 5*5*5*5 = 625

No:

5**4 = 1*5*5*5*5
5**3 = 1*5*5*5
5**2 = 1*5*5
5**1 = 1*5
5**0 = 1

-- 
Greg

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: Decimals and other numbers Devin Jeanpierre <jeanpierreda@gmail.com> - 2015-01-08 19:02 -0800
  Re: Decimals and other numbers Marko Rauhamaa <marko@pacujo.net> - 2015-01-09 09:28 +0200
    Re: Decimals and other numbers Chris Angelico <rosuav@gmail.com> - 2015-01-09 18:37 +1100
      Re: Decimals and other numbers Marko Rauhamaa <marko@pacujo.net> - 2015-01-09 11:31 +0200
    Re: Decimals and other numbers Dave Angel <davea@davea.name> - 2015-01-09 02:49 -0500
    Re: Decimals and other numbers Devin Jeanpierre <jeanpierreda@gmail.com> - 2015-01-09 00:51 -0800
      Re: Decimals and other numbers Jussi Piitulainen <jpiitula@ling.helsinki.fi> - 2015-01-09 11:07 +0200
        [OT] x**y == y**x Peter Pearson <pkpearson@nowhere.invalid> - 2015-01-09 17:46 +0000
          Re: [OT] x**y == y**x Marko Rauhamaa <marko@pacujo.net> - 2015-01-09 23:41 +0200
            Re: [OT] x**y == y**x Peter Pearson <pkpearson@nowhere.invalid> - 2015-01-10 16:57 +0000
  Re: Decimals and other numbers Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-01-09 19:49 +1100
    Re: Decimals and other numbers Devin Jeanpierre <jeanpierreda@gmail.com> - 2015-01-09 00:58 -0800
      Re: Decimals and other numbers Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-01-09 21:20 +1100
        Re: Decimals and other numbers Chris Angelico <rosuav@gmail.com> - 2015-01-09 21:39 +1100
          Re: Decimals and other numbers Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-01-09 23:24 +1100
            Re: Decimals and other numbers Chris Angelico <rosuav@gmail.com> - 2015-01-09 23:34 +1100
        Re: Decimals and other numbers Devin Jeanpierre <jeanpierreda@gmail.com> - 2015-01-09 17:25 -0800
        Re: Decimals and other numbers Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2015-01-10 16:08 +1300
    Re: Decimals and other numbers Devin Jeanpierre <jeanpierreda@gmail.com> - 2015-01-09 01:11 -0800
    Re: Decimals and other numbers Marko Rauhamaa <marko@pacujo.net> - 2015-01-09 11:34 +0200
      Re: Decimals and other numbers Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-01-09 22:03 +1100
    Re: Decimals and other numbers Marko Rauhamaa <marko@pacujo.net> - 2015-01-09 11:44 +0200
    Re: Decimals and other numbers Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2015-01-10 16:05 +1300
      Re: Decimals and other numbers Devin Jeanpierre <jeanpierreda@gmail.com> - 2015-01-09 19:57 -0800

csiph-web