string issue

Francis Girard francis.girard at free.fr
Sun Feb 6 16:44:42 EST 2005


Yes, I also this that comprehension is the clearer way to handle this. You 
might also consider the good old "filter" function :

ips = filter(lambda ip: '255' not in ip, ips)

Francis Girard

Le vendredi 4 Février 2005 20:38, rbt a écrit :
> Thanks guys... list comprehension it is!
>
> Bill Mill wrote:
> >>>>ips = [ip for ip in ips if '255' not in ip]
> >>>>ips




More information about the Python-list mailing list