1#use count():
2>>> my_list = [1, 2, 3, 1, 4]
3>>> print(my_list.count(1))
42
5
6#OR, you can also use counter:
7>>> from collections import Counter
8>>> z = ['blue', 'red', 'blue', 'yellow', 'blue', 'red']
9>>> Counter(z)
10Counter({'blue': 3, 'red': 2, 'yellow': 1})