input: Write a function to create a Python program that takes in a positive integer, then uses a while loop to output the numbers counting down to 1. If the input number is positive, return the list of numbers in descending order. If the input is invalid or non-positive, return an empty list.
  
  Example usage:
  assert countdown(6) == [6, 5, 4, 3, 2, 1]
  assert countdown(0) == []
  assert countdown(-5) == []
  assert countdown(1) == [1]
output: def countdown(n):
      if n <= 0:
          return []
      result = []
      while n > 0:
          result.append(n)
          n -= 1
      return result