[Tutor] Lists...

Remco Gerlich scarblac@pino.selwerd.nl
Sun, 3 Jun 2001 22:08:08 +0200


On  0, alan.gauld@bt.com wrote:
> > def intersect_eas(L1, L2):
> >     '''The easiest way for Alan G, requires nested_scopes'''
> >     return filter(lambda x: (x in L2), L1)
> 
> How does it require nested scopes?
> lambda and filter are builtin, 
> and x,L1 and L2 are all locals.

L1 and L2 are not locals inside the lambda. They're only visible with nested
scopes.

-- 
Remco Gerlich