split list into multiple lists python
def split_list(a_list, number):
splitNumber = len(a_list) // number
result = [a_list[x:x+splitNumber] for x in range(0, len(a_list), splitNumber)]
if(len(result) > number):
result[len(result) - 2] = result[len(result) - 2]+ result[len(result)-1]
result.pop()
return result
a = [i for i in range(11)]
print(split_list(a,3))