Insertion sort in Python

def insertion_sort(the_array):
    j = 0
    for i in range(1, len(the_array)):
    j = i
    while ((j > 0) and (the_array[j] < the_array[j-1])):
        the_array[j], the_array[j - 1] = the_array[j - 1], the_array[j]
        j = j - 1