input: Write a python function to count the number of occurrences of a given element in an array.
  assert countOccurrences([2, 3, 3, 10, 12], 3) == 2
  assert countOccurrences([1, 2, 2, 2, 3, 4], 2) == 3
  assert countOccurrences([5, 5, 5, 5, 5], 5) == 5
  assert countOccurrences([1, 2, 3, 4, 5], 6) == 0
output: def countOccurrences(arr, element):
      return arr.count(element)