i want to sort this list in python from a file : 
    def insertionSort(a):
    for i in range(1, len(a)): #outloop covering the range 
        value = a[i] #value = to list, which will compare items to the left
        i = i - 1 #i goes lower than index to comapre futher to the left
        while i >= 0 : #keep comparing till its at the begining of the list
            if value < a[i]: #if value is less than i
                a[i+1] = a[i] # shift number in right i to slot i + 1
                a[i] = value # shift value that was left into slot i
                i = i - 1 
            else: 
                break



    infile = open("file1.txt", "r")
    a=[]
    for aline in infile:
    a = aline.split()
    
    insertionSort(a)
    
    print(a)
    
this is what it is in the file
7686850495948548545


how do i get the insertionSort function to work on file?
    
    