Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!feeder.news-service.com!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.017 X-Spam-Evidence: '*H*': 0.97; '*S*': 0.00; 'dictionary': 0.07; 'csv': 0.09; 'pm,': 0.11; 'skip:[ 20': 0.12; 'wrote:': 0.14; 'ideal.': 0.16; 'subject:Pythonic': 0.16; 'seems': 0.21; 'header:In-Reply- To:1': 0.22; 'file,': 0.22; 'received:209.85.214.174': 0.23; 'received:mail-iw0-f174.google.com': 0.23; 'structure': 0.24; 'message-id:@mail.gmail.com': 0.28; 'subject:?': 0.29; 'fri,': 0.29; 'control.': 0.31; 'to:addr:python-list': 0.32; 'initial': 0.32; 'skip:v 20': 0.35; 'data': 0.37; 'received:209.85': 0.37; 'apr': 0.38; 'received:google.com': 0.38; 'less': 0.38; 'received:209.85.214': 0.39; 'under': 0.39; 'to:addr:python.org': 0.39; 'comes': 0.39; 'received:209': 0.39; 'header:Received:5': 0.40; 'might': 0.40; '2011': 0.62 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=xXu2PoYBSOH/eco7HYWEHMPKCX47UXoYw5i+MOvRE0M=; b=qqUx5o5UZgK6oAti+CDqyuNAan6vmUryBQC0WWPx/Z9y/EBgbp+zOc4NCcbSuMB3Cb 2anbfiRByeY1ykTaBZc048Xr1b+qp9TJ25EAJiRZqHTk4VMnWJJ/nQZS52qDH35OJiOu UYL+xdjeitLqxlOPFF+uEVeu7tAqMGk3xm7Vo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=cwlYS2y83IxvgolVGoq0Xhf89W3TLjL3nlPEF3q48k/pUtvETGQt+myu19jXOnBSEd 0vKxlKjc795FnKDXUjOSBJaRdvThvSVqq0hIGPryV2VTO/8YLHaGabSYAZwzJG5SvmaK PEp4i4A4Oq5syXWvdrYvCbfiNFgayQPEBXjTk= MIME-Version: 1.0 In-Reply-To: References: Date: Fri, 15 Apr 2011 18:32:23 +1000 Subject: Re: Pythonic infinite for loop? From: Chris Angelico To: python-list@python.org Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 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: 11 NNTP-Posting-Host: 82.94.164.166 X-Trace: 1302856351 news.xs4all.nl 81481 [::ffff:82.94.164.166]:34141 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:3253 On Fri, Apr 15, 2011 at 6:25 PM, Peter Otten <__peter__@web.de> wrote: > The initial data structure seems less than ideal. You might be able to > replace it with a dictionary like > > {"Keyword": [value_for_keyword_1, value_for_keyword_2, ...]} > > if you try hard enough. The initial data structure comes from a CSV file, and is not under my control. ChrisA