input: Write a function to count the occurrence of each character in a given input string. Return a dictionary where the keys are the characters and the values are the number of times each character appears. If the input string is empty, return an empty dictionary.
  
  def char_occurrences(a_string):
   char_count = {}
   for char in a_string:
   if char in char_count:
   char_count[char] += 1
   else:
   char_count[char] = 1
   return char_count
  
  assert char_occurrences("Hello, World!")=={'H': 1, 'e': 1, 'l': 3, 'o': 2, ',': 1, ' ': 1, 'W': 1, 'r': 1, 'd': 1, '!': 1}
  assert char_occurrences("aaabbbccc")=={'a': 3, 'b': 3, 'c': 3}
  assert char_occurrences("Mississippi")=={'M': 1, 'i': 4, 's': 4, 'p': 2}
  assert char_occurrences("")=={}
  assert char_occurrences("123321")=={'1': 2, '2': 2, '3': 2}
output: def char_occurrences(a_string):
      char_count = {}
      for char in a_string:
          if char in char_count:
              char_count[char] += 1
          else:
              char_count[char] = 1
      return char_count