Steven D'Aprano <[EMAIL PROTECTED]> writes:
> or even
> 
> len(filter(lambda t, y=y: y>t, x))


How about 

   min(i for i,t in enumerate(x) if t >= y)

or

   max(i for i,t in enumerate(x) if t <= y)

Those are actually pretty direct.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to