how to count how many times a number appears in an array in python code example Example: count how many times a value appears in array python >>> [1, 2, 3, 4, 1, 4, 1].count(1) 3