Re: Unpacking a list of strings

2006-04-27 Thread Alex Martelli
Panos Laganakos <[EMAIL PROTECTED]> wrote: > Is there some other practice than reading all the strings and slicing > them later? > > They're stored in the form of: > List Group[10]: > char[17] name; > > So I thought of doing: > unpacked = unpack('%s' % (10*17), data) > > And then slicing th

Unpacking a list of strings

2006-04-27 Thread Panos Laganakos
Is there some other practice than reading all the strings and slicing them later? They're stored in the form of: List Group[10]: char[17] name; So I thought of doing: unpacked = unpack('%s' % (10*17), data) And then slicing the list by a step of 17. Is there some way to have unpack return a