input: Write a function to print the top 5 most frequent words in a given sentence. If the sentence is empty, print an empty list.
  assert top_5_frequent_words("Python is an interpreted, high-level, general-purpose programming language.")==[('Python', 1), ('is', 1), ('an', 1), ('interpreted,', 1), ('high-level,', 1)]
  assert top_5_frequent_words("The quick brown fox jumps over the lazy dog and the quick brown cat jumps over the lazy dog.")==[('the', 4), ('over', 2), ('lazy', 2), ('dog', 2), ('jumps', 2)]
  assert top_5_frequent_words("")==[]
  assert top_5_frequent_words("a a a a b b b c c d")==[('a', 4), ('b', 3), ('c', 2), ('d', 1)]
  assert top_5_frequent_words("Python is fun and Python is easy but Python is powerful")==[('Python', 3), ('is', 3), ('and', 1), ('fun', 1), ('easy', 1)]
output: def top_5_frequent_words(sentence):
      if not sentence:
          return []
      words = sentence.split()
      freq = {}
      for word in words:
          if word in freq:
              freq[word] += 1
          else:
              freq[word] = 1
      sorted_freq = sorted(freq.items(), key=lambda item: (-item[1], item[0]))
      return sorted_freq[:5]