input: Write a function to generate a program that sorts a list of numbers using the Insertion Sort algorithm in Python. The function should return the sorted list. If the input list is empty, the function should return an empty list.
  assert insertionSort([2, 4, 7, 3, 8, 6, 1])==[1, 2, 3, 4, 6, 7, 8]
  assert insertionSort([])==[]
  assert insertionSort([9, 8, 7, 6, 5, 4, 3, 2, 1])==[1, 2, 3, 4, 5, 6, 7, 8, 9]
  assert insertionSort([1, 2, 3, 4, 5, 6, 7, 8, 9])==[1, 2, 3, 4, 5, 6, 7, 8, 9]
  assert insertionSort([5, 3, 8, 6, 7, 2])==[2, 3, 5, 6, 7, 8]
output: def insertionSort(arr):
      if not arr:
          return []
      for i in range(1, len(arr)):
          key = arr[i]
          j = i - 1
          while j >= 0 and key < arr[j]:
              arr[j + 1] = arr[j]
              j -= 1
          arr[j + 1] = key
      return arr