Help me in solving AO17 problem

My issue

My code

# Update the code below to solve this problem

t = int(input())
for i in range(t):
    N = int(input())
    A = list(map(int, input().split()))
    B = list(map(int, input().split()))

Learning course: Solve Programming problems using Python
Problem Link: CodeChef: Practical coding for everyone

The logic is sum up the elements of array A and B separately say sumA and sumB then subtract the maximum value of A from sumA and maximum value of B from sumB .
Then if sumA==sumB then its a draw
if sumA<sumB then alice wins
else Bob wins.