Closed
Description
opened on Feb 2, 2017
I think it would be useful to add a method of count
that takes a single iterable argument of booleans and returns the number of true
elements.
For example (imagine that the function iseven
does not exist), I find this:
count(i % 2 == 0 for i in 1:10)
to be more readable than this:
count(i -> i % 2 == 0, 1:10)
Activity