input: Write a function to return a list of words that appear at least n times in a given list of words. If the given list is empty then return an empty list.
  def frequent_words(words, n):
      if not words:
          return []
      from collections import Counter
      counts = Counter(words)
      return [word for word, count in counts.items() if count >= n]
  assert frequent_words(['a', 'b', 'a', 'c', 'd', 'a', 'x', 'd', 'd'], 3)==['a', 'd']
  assert frequent_words(['hello', 'world', 'hello'], 2)==['hello']
  assert frequent_words(['a', 'b', 'c'], 1)==['a', 'b', 'c']
  assert frequent_words(['one', 'one', 'two', 'two', 'three', 'three'], 3)==[]
  assert frequent_words([], 3)==[]
output: def frequent_words(words, n):
      if not words:
          return []
      from collections import Counter
      counts = Counter(words)
      return [word for word, count in counts.items() if count >= n]