Enum

count/2

count(enumerable, fun)

Returns the count of elements in enumerable for which fun returns a truthy value.