sort and delete ?
matt at virtualspectator.com
Tue May 30 06:05:00 EDT 2000
Is there a more "pythonic" way to do the following, which, before I make a mess
is, suppossed to assess whether to throw elements out of a list and then
actually do so. I use a rather strange, but database-like, list.
a = [['egg', [1, 'ace', 3]], ['apple', [1, 'two', 3]], ['pear', [4, 'three',
6]], ['orange', [5, 'two', 1]]]
for i in a:
if i in ('ace','three'):
More information about the Python-list