input: Write a function to generate a Python program which takes a string as input and prints all of its substrings in order from longest to shortest length. If the input string is empty, the function should return an empty list.
  assert substring_in_order("abc")==['abc', 'ab', 'bc', 'a', 'b', 'c']
  assert substring_in_order("python")==['python', 'pytho', 'pyth', 'pyt', 'py', 'pt', 'tho', 'th', 't', 'on', 'o', 'n']
  assert substring_in_order("")==[]
output: def substring_in_order(s):
      substrings = []
      n = len(s)
      for length in range(n, 0, -1):
          for start in range(n - length + 1):
              substrings.append(s[start:start + length])
      return substrings