Answer the question
In order to leave comments, you need to log in
Is there a function in Python that will display the number of elements?
Hello
In the title, I shortened the question a little, so the answer "len(foo)" will not help
. So, is there a built-in function in Python that can return how many times a certain element occurs in a list?
In order not to prescribe a cycle and not to import any modules.
Something like this
All_Elements = [1, 1, 5, 3, 2, 1]
function(All_Elements, 1) # 3
Answer the question
In order to leave comments, you need to log in
1) simplehtmldom
2) phpquery
2) for simple cases - regular expressions
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question