I am opening a text file and appending the index[1] of it to a list, with the output being ['18.0', '15', '8.50', '10.50']. My desired output is [18, 15, 8.5, 10.5].
file = open(file, "r")
sheet = sheet = [line.strip() for line in theFile]
del sheet[0]
sheet.sort()
for i in sheet:
lines = (i.split(','))
list.append(lines[1])