input: Write a function to count the occurrences of a given number in a list.
  assert count_occurrences([1, 2, 3, 4, 1, 2, 1, 1], 1) == 4
  assert count_occurrences([1, 2, 3, 4, 1, 2, 1, 1], 2) == 2
  assert count_occurrences([1, 2, 3, 4, 1, 2, 1, 1], 3) == 1
output: def count_occurrences(lst, num):
      return lst.count(num)