As bereal says, you can just use list comparison for this. If ties weren't an issue, you could just use max() to determine a winner, but to handle ties you need to sort the whole collection of lists.
Eg, this code will handle any number of lists.
list1 = [50,9,5,4,5]
list2 = [50,9,8,1,6]
list3 = [50,9,8,1,5]
lists = [(seq, i) for i, seq in enumerate((list1, list2, list3), 1)]
lists.sort(reverse=True)
if lists[0][0] == lists[1][0]:
print("it's a tie")
else:
print("list {0} wins: {1}".format(lists[0][1], lists[0][0]))
output
list 2 wins: [50, 9, 8, 1, 6]
If you change list2 back to [50, 9, 8, 1, 6], then it's a tie will get printed.
lists is a list of tuples, with each tuple containing one of the original lists and its index number, so we can identify lists after the tuples have been sorted. The sorting will compare the lists, and if two lists are identical, then the indices will also be compared, but that doesn't affect the desired outcome here.
BTW, list1[1:2] > list2[1:2] is wasteful. It creates a new pair of single element lists & compares them. It's easier to just compare the elements themselves, eg list1[1] > list2[1].
while? in this casewhileworks likeifbecause ofbreaksum(candidate1) -> 48