Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #105540
| Path | csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail |
|---|---|
| From | INADA Naoki <songofacandy@gmail.com> |
| Newsgroups | comp.lang.python |
| Subject | Re: 0 equals False, was Re: (unknown) |
| Date | Wed, 23 Mar 2016 11:12:40 +0000 |
| Lines | 7 |
| Message-ID | <mailman.48.1458731602.2244.python-list@python.org> (permalink) |
| References | <CAFWQgO=o-rPavakLZZBRxAthM5g7xE=Mn4hwcFPxTUvCEXn7SQ@mail.gmail.com> <nctleq$5t6$1@ger.gmane.org> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=UTF-8 |
| X-Trace | news.uni-berlin.de IoG759dc6u85BgZuwXx/IAZuTLetNGfDMl3OxlaafttA== |
| Return-Path | <songofacandy@gmail.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.019 |
| X-Spam-Evidence | '*H*': 0.96; '*S*': 0.00; 'received:209.85.223': 0.03; 'def': 0.13; '>>>': 0.15; 'received:io': 0.16; 'received:psf.io': 0.16; '>>>': 0.20; 'header:In-Reply-To:1': 0.24; 'message-id:@mail.gmail.com': 0.27; 'received:google.com': 0.35; 'received:209.85': 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'received:209': 0.38; 'to:addr:python.org': 0.40 |
| DKIM-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=2x4yYKC7kf4V+K6J7YLOJhE+U5H+G/v4S3SJ6KYuZn0=; b=CJ7aydx4LQLSsSnIwVr7l3YlFwdTBjwgW/a1OZmGjsGasvuKzuOSgAr8i07lGLhRju iYvr4LUW79U4abEDDRXN5i1qx/X5HNYzQTDvrBvNLnoY0bOqrjzkmKEl1wqV92tjJerO jOMwOtMcAEVcvu6p/KUKFF5g6fIpWuouuB0/EAJh1FZKwfJjv9401hTHaMHXDyvldl8M buMJqgweNraP5i3+3MEYYdsnYKTRfLI7Wrkx8DWsXk8kqck4H+iHAp0TMKdNT+bct87C f3JPuOEdbtBid1BgLC4c1eBlRDyDqmnyQX+LFPO8K3h4uTqv6w/wHfOi1n1Fy536sMaf DYOA== |
| X-Google-DKIM-Signature | v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=2x4yYKC7kf4V+K6J7YLOJhE+U5H+G/v4S3SJ6KYuZn0=; b=klpXutz0oqcmNfMpTs1as32ZSloccgfRq1A9AnOS8Og8E5saZVaJLqDfNHeT7CeCCK PgiJPg4uOHr4nynwmgc60/eR3CohUpwrvl+79yTqDTqEOMHeSb+bq6d+WhLFY5oKuYKb RnPuIRzn3nkofKoQ+mqIYOT2xmEwcY8JVza3zqAgnkCmXAx92sTnMnmSA6DfGhw1G4Hb qRAEh/YMKeKEBZyMzUd7TeUUyF+fLKchS8sQziVcBE6UJzkT/vmg+XBZ99mdTMOmbdAq /SGI9UuiTOEVnUYOmW3LKle3G+YB6mBzVaFjmdhTIUXReyJxcgcDrqhyZay9gcsj7FZ7 CTSA== |
| X-Gm-Message-State | AD7BkJIUxSWgSp1c2iaXzz3onemMrzkk8cjOdUSWhPf22QbEs3xWEjOxLyIDrR0QX5m9AwbEWyxDMPweZW/TwA== |
| X-Received | by 10.50.72.107 with SMTP id c11mr2741574igv.85.1458731569356; Wed, 23 Mar 2016 04:12:49 -0700 (PDT) |
| In-Reply-To | <nctleq$5t6$1@ger.gmane.org> |
| X-Content-Filtered-By | Mailman/MimeDel 2.1.21 |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.21 |
| 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> |
| Xref | csiph.com comp.lang.python:105540 |
Show key headers only | View raw
Tips: Since True == 1, sum() can count Trues. >>> def count_even(seq): ... return sum(i%2 == 0 for i in seq) >>> count_even(range(100)) 50
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: 0 equals False, was Re: (unknown) INADA Naoki <songofacandy@gmail.com> - 2016-03-23 11:12 +0000
csiph-web