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


Groups > comp.lang.python > #73302

Re: Python's numeric tower

Path csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <rosuav@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.009
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; '16,': 0.03; 'subject:Python': 0.06; 'method,': 0.09; 'sure,': 0.09; 'type,': 0.09; 'cc:addr:python-list': 0.11; '1),': 0.16; 'already!': 0.16; 'docstring': 0.16; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'roy': 0.16; 'throw': 0.16; 'wrote:': 0.18; 'bit': 0.19; 'cc:addr:python.org': 0.22; 'mon,': 0.24; 'cc:2**0': 0.24; 'defined': 0.27; 'header:In-Reply-To:1': 0.27; 'chris': 0.29; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; "i'm": 0.30; 'too.': 0.31; 'operators': 0.31; 'probably': 0.32; 'guess': 0.33; 'definition': 0.35; 'but': 0.35; 'received:google.com': 0.35; 'list': 0.37; 'sure': 0.39; 'number,': 0.60; 'tell': 0.60; 'numbers': 0.61; 'sum': 0.64; 'smith': 0.68; 'guaranteed': 0.75; 'article': 0.77; 'hand': 0.80; 'to:none': 0.92
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:cc :content-type; bh=FnI2H7pH9i32QD9zDwfQiSZMZixf5/YadX/P8YaN/DM=; b=Pin+OaUTNwkQB5o8ts0rMglEe6pSwGswbitKj+rYfSY2qWTmzeTgBIQHg601WeUwUW yEHNiuV4fp2vGshi8wOmGEaj7+Doc9Ofk/lcJ+D7esT0xATQlyzF5TeRH3+IwvXKHMxF DioswacGGM1XzchDv7GCIyiZz6GhtSBggerVBwQvEWYqwwHbAh6F7Zy0S5kBByaMCqm3 8J5oYUQggadsi6VzXYriQLio9l8eX4Nltl+ne+ab9zqLKYYEqPUGB/Oi3x9s8QzSHUce pEMkW0qKrb0RSCvCm4Fvbml7yFvjuHHXzzweT7zwNZrmPabZ8WDIJ1eyxVd4TSYZ1PYa B0oA==
MIME-Version 1.0
X-Received by 10.58.85.3 with SMTP id d3mr9245vez.34.1402884246942; Sun, 15 Jun 2014 19:04:06 -0700 (PDT)
In-Reply-To <roy-019E1B.21575015062014@news.panix.com>
References <539d0a40$0$29988$c3e8da3$5496439d@news.astraweb.com> <mailman.11068.1402818363.18130.python-list@python.org> <539dbcbe$0$29988$c3e8da3$5496439d@news.astraweb.com> <roy-671447.13284415062014@news.panix.com> <539e3c95$0$29988$c3e8da3$5496439d@news.astraweb.com> <mailman.11074.1402880950.18130.python-list@python.org> <roy-019E1B.21575015062014@news.panix.com>
Date Mon, 16 Jun 2014 12:04:06 +1000
Subject Re: Python's numeric tower
From Chris Angelico <rosuav@gmail.com>
Cc "python-list@python.org" <python-list@python.org>
Content-Type text/plain; charset=UTF-8
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.11075.1402884256.18130.python-list@python.org> (permalink)
Lines 17
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1402884256 news.xs4all.nl 2890 [2001:888:2000:d::a6]:53156
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:73302

Show key headers only | View raw


On Mon, Jun 16, 2014 at 11:57 AM, Roy Smith <roy@panix.com> wrote:
> In article <mailman.11074.1402880950.18130.python-list@python.org>,
>  Chris Angelico <rosuav@gmail.com> wrote:
>
>> I guess if you have a list of Numbers that are all the same type, you
>> can probably sum them, but you can sum non-Numbers too. The docstring
>> is a bit vague - sure, it's a number, but what can you do with it?
>
> You can use it to count to three!

Since "increment" is not a provided method, and the + and += operators
are not guaranteed to be defined for any definition of 1 on the other
side, I'm not sure that's actually true... but if you hold a hand
grenade and want to know whether to count to Decimal('3') or 3+0j or
Fraction(3, 1), I'm just going to tell you to throw the thing already!

ChrisA

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


Thread

Python's numeric tower Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-06-15 02:51 +0000
  Re: Python's numeric tower Ian Kelly <ian.g.kelly@gmail.com> - 2014-06-15 01:22 -0600
    Re: Python's numeric tower Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-06-15 15:33 +0000
      Re: Python's numeric tower Roy Smith <roy@panix.com> - 2014-06-15 13:28 -0400
        Re: Python's numeric tower Ian Kelly <ian.g.kelly@gmail.com> - 2014-06-15 11:45 -0600
        Re: Python's numeric tower Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-06-16 00:38 +0000
          Re: Python's numeric tower Chris Angelico <rosuav@gmail.com> - 2014-06-16 11:02 +1000
            Re: Python's numeric tower Roy Smith <roy@panix.com> - 2014-06-15 21:57 -0400
              Re: Python's numeric tower Chris Angelico <rosuav@gmail.com> - 2014-06-16 12:04 +1000
                Re: Python's numeric tower Roy Smith <roy@panix.com> - 2014-06-15 22:17 -0400
                Re: Python's numeric tower Dan Sommers <dan@tombstonezero.net> - 2014-06-16 03:38 +0000
                Re: Python's numeric tower Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-06-16 09:29 +0100
                Re: Python's numeric tower Roy Smith <roy@panix.com> - 2014-06-15 23:48 -0400

csiph-web