input: Write a function to count the occurrences of each word in a sentence.
  assert word_occurrences('The quick brown fox jumps over the lazy dog')=={'The': 1, 'quick': 1, 'brown': 1, 'fox': 1, 'jumps': 1, 'over': 1, 'the': 1, 'lazy': 1, 'dog': 1}
  assert word_occurrences('hello world hello')=={'hello': 2, 'world': 1}
  assert word_occurrences('a a a b b c')=={'a': 3, 'b': 2, 'c': 1}
output: def word_occurrences(sentence):
      words = sentence.split()
      occurrences = {}
      for word in words:
          if word in occurrences:
              occurrences[word] += 1
          else:
              occurrences[word] = 1
      return occurrences