Counts the number of elements in the source.
Type of items in the source.
Predicate function to determine if an element should be counted.
Collector that counts the number of elements in the source.
const result = count<number>()([1, 2, 3]);console.log(result); // 3 Copy
const result = count<number>()([1, 2, 3]);console.log(result); // 3
Counts the number of elements in the source.