Re: a_list.count(a_callable) ?




print "b has", b.count(25, cmp=le, key=attrgetter("age")), \
"elements with age <= 25."
[deleted]
b has 2 elements with age <= 30.

Oops, I mixed up when copying and pasting at different times... :p
The output was of course

b has 1 elements with age <= 25.

Ping

.



Relevant Pages

  • Re: (RSPW HOF 08) Nominations : Day 4
    ... Oops. ... I'll fix that, I was copying and pasting without paying ...
    (rec.sport.pro-wrestling)
  • Re: Connections and Transactions
    ... I was copying and pasting and realized that i didn't copy commit() ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: hello everyone!
    ... Oops, I forgot to add this: :-) ... Being well past the half-century mark in age myself, ... I'm rapidly catching up to your own dotage. ...
    (rec.bicycles.misc)
  • Re: grumblesmurf
    ... Any RightPondian denizens of a Certain Age ... recollect the number 1771, frex? ... Oops, wrong number. ...
    (alt.sysadmin.recovery)
  • Re: Coming back to Basic after many years
    ... listed in the keywords for RISC OS BASIC. ... I'm afraid not; this shows BASIC's age. ... IF oops THEN ENDPROC ...
    (comp.sys.acorn.programmer)