def count(self, func):
        n = 0
        for element in self:
            if func(element):
                n += 1
        return n
Counts the number of elements in the sequence which satisfy the predicate func.
dataset/ETHPy150Open EntilZha/PyFunctional/functional/pipeline.py/Sequence.count