Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #58258
| Path | csiph.com!usenet.pasdenom.info!gegeweb.org!usenet-fr.net!proxad.net!feeder1-2.proxad.net!news.tele.dk!news.tele.dk!small.news.tele.dk!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.034 |
| X-Spam-Evidence | '*H*': 0.93; '*S*': 0.00; 'anyway.': 0.05; 'cursor': 0.09; 'iterate': 0.09; 'subject:question': 0.10; 'from:addr:rosuav': 0.16; 'from:name:chris angelico': 0.16; 'goebel': 0.16; 'iterator': 0.16; 'sqlite': 0.16; 'index': 0.16; 'wrote:': 0.18; 'solution.': 0.20; 'select': 0.22; 'looks': 0.24; 'header:In-Reply-To:1': 0.27; 'have,': 0.30; 'message- id:@mail.gmail.com': 0.30; 'gives': 0.31; 'easy,': 0.31; 'object.': 0.31; 'once,': 0.31; 'probably': 0.32; 'fri,': 0.33; 'could': 0.34; 'something': 0.35; 'received:google.com': 0.35; 'data,': 0.36; 'nov': 0.38; 'to:addr:python-list': 0.38; 'list,': 0.38; 'pm,': 0.38; 'to:addr:python.org': 0.39; 'problems.': 0.60; "you're": 0.61; 'back': 0.62; 'more': 0.64; 'hints': 0.68; 'forth': 0.81; 'good!': 0.84; '2013': 0.98 |
| 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:to :content-type; bh=Xza1wpSimf8kY1g7HH+KSjIlwhARggXi69TVLorzkKk=; b=lcEMVB1MRK3Zi59EeOEawnNaf87uPmm9WwbAVZgoQXp5A50dveEc7XF9Zi2He6bZms LV/9IEOT2frVMtNwYM8COS7tPC9uGsm8Y1Ndi2ITT2cvyUpep2E5IlJmSXfpSWKBqQeL OAGcoLWN6S5ZqfTxKTUQeBMFvPBezLYkGPdj3IJdfd/KwqVWkFJiERr1AQiMgHlb7Qer iENYOY6B4t2pLj0KAFgKXZPzPCA4QWWR5BuZLe2fjYCJYrK939G7r1OCiWfoILSg0Su8 T2FmNG5kNcWZU9/PtQP9zuOKBgS3cIuhHyBHVjuDwleqPEngmXyfazpDDpB5mETt0vl5 Xu7Q== |
| MIME-Version | 1.0 |
| X-Received | by 10.66.26.236 with SMTP id o12mr2848743pag.136.1383306900468; Fri, 01 Nov 2013 04:55:00 -0700 (PDT) |
| In-Reply-To | <52737FDF.6080306@fam-goebel.de> |
| References | <5272CBA8.3070800@fam-goebel.de> <l4uluh$l7s$1@ger.gmane.org> <52737FDF.6080306@fam-goebel.de> |
| Date | Fri, 1 Nov 2013 22:55:00 +1100 |
| Subject | Re: "Backward"-Iterator - Beginners question |
| From | Chris Angelico <rosuav@gmail.com> |
| To | python-list@python.org |
| Content-Type | text/plain; charset=ISO-8859-1 |
| 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.1920.1383306910.18130.python-list@python.org> (permalink) |
| Lines | 11 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1383306910 news.xs4all.nl 15903 [2001:888:2000:d::a6]:54914 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:58258 |
Show key headers only | View raw
On Fri, Nov 1, 2013 at 9:18 PM, Ulrich Goebel <ml@fam-goebel.de> wrote: > That gives me the solution. What I have, is an iterator object comming as a > SQLite database cursor object. So I could minimize the underliying SELECT > and build index = list(cursor). Then with Your hints I get what I want. Looks good! If you need to iterate over something more than once, or go back and forth through it a bit, this is probably the best general solution anyway. With a list, heaps of things are easy, and unless you're working with gobs of data, you won't have any problems. ChrisA
Back to comp.lang.python | Previous | Next — Next in thread | Find similar | Unroll thread
Re: "Backward"-Iterator - Beginners question Chris Angelico <rosuav@gmail.com> - 2013-11-01 22:55 +1100 Re: "Backward"-Iterator - Beginners question patrick vrijlandt <patrick.vrijlandt@gmail.com> - 2013-11-01 20:09 +0000
csiph-web