Files
wren/doc/site/core
Thorbjørn Lindeijer 94804fe1a0 Added Sequence.count(predicate)
Returns the number of elements in the sequence that pass the
`predicate`.

It could also have been implemented as:

  count(f) { reduce(0) {|a, b| f.call(b) ? a + 1 : a } }

But I considered the simple version more readable.

Also documented Sequence.count.
2015-03-19 21:10:05 +01:00
..
2015-01-18 15:36:36 -08:00
2015-03-14 09:48:45 -07:00
2015-02-22 12:34:32 -08:00
2015-03-19 21:10:05 +01:00
2015-01-18 15:36:36 -08:00
2015-02-27 07:37:58 -08:00
2015-01-18 15:36:36 -08:00
2015-01-18 15:36:36 -08:00