input: Write a python function to count the frequency of each character in a given string.
  assert count_characters('hello world!') == {'h': 1, 'e': 1, 'l': 3, 'o': 2, ' ': 1, 'w': 1, 'r': 1, 'd': 1, '!': 1}
  assert count_characters('aabbcc') == {'a': 2, 'b': 2, 'c': 2}
  assert count_characters('') == {}
output: def count_characters(s):
      freq = {}
      for char in s:
          if char in freq:
              freq[char] += 1
          else:
              freq[char] = 1
      return freq