Pythonic infinite for loop?

Steven D'Aprano steve+comp.lang.python at pearwood.info
Fri Apr 15 08:48:56 EDT 2011


On 2011年4月15日 18:32:23 +1000, Chris Angelico wrote:
> On Fri, Apr 15, 2011 at 6:25 PM, Peter Otten <__peter__ at 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.

There's no reason to duplicate the CSV file's design in your own data 
structures though.
-- 
Steven


More information about the Python-list mailing list

AltStyle によって変換されたページ (->オリジナル) /