a list/re problem

Neil Cerutti neilc at norwich.edu
Fri Dec 11 16:16:25 EST 2009


On 2009-12-11, Grant Edwards <invalid at invalid.invalid> wrote:
> [s[1:-1] for s in l if (s[0] == s[-1] == '*')]

That last bit doesn't work right, does it, since an == expression
evaluates to True or False, no the true or false value itself?

-- 
Neil Cerutti



More information about the Python-list mailing list