input: Write a function `substring_in_order(string)` that takes a string as input and returns a list of all its substrings in order from the longest to the 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("hello")==['hello', 'hell', 'ello', 'hel', 'ell', 'llo', 'he', 'el', 'll', 'lo', 'h', 'e', 'l', 'l', 'o']
  assert substring_in_order("")==[]
  assert substring_in_order("a")==['a']
output: def substring_in_order(string):
      substrings = []
      length = len(string)
      for i in range(length):
          for j in range(i + 1, length + 1):
              substrings.append(string[i:j])
      substrings.sort(key=len, reverse=True)
      return substrings