input: Write a python function to calculate word frequency in a list of strings and return a list of dictionaries.
  assert word_freq_dicts(["a a a", "b b b", "a b a"]) == [{'a': 3}, {'b': 3}, {'a': 2, 'b': 1}]
  assert word_freq_dicts(["cat dog cat", "dog cat", "cat cat"]) == [{'cat': 2, 'dog': 1}, {'dog': 1, 'cat': 1}, {'cat': 2}]
  assert word_freq_dicts(["hello world", "world hello", "hello"]) == [{'hello': 1, 'world': 1}, {'world': 1, 'hello': 1}, {'hello': 1}]
output: def word_freq_dicts(strings):
      result = []
      for s in strings:
          words = s.split()
          freq_dict = {}
          for word in words:
              if word in freq_dict:
                  freq_dict[word] += 1
              else:
                  freq_dict[word] = 1
          result.append(freq_dict)
      return result