SyntaxFix
Write A Post
Hire A Developer
Questions
You can also use countOf method of a built-in module operator.
countOf
operator
>>> import operator >>> operator.countOf([1, 2, 3, 4, 1, 4, 1], 1) 3