You are viewing a single comment's thread. Return to all comments →
def maxx(a,b): if a==b: return 2 elif a>b: return 0 else: return 1 def compareTriplets(a, b): # Write your code here score=[0]*3 for i in range(0,len(a)): winner=maxx(a[i],b[i]) score[winner]+=1 score.pop() return score
Seems like cookies are disabled on this browser, please enable them to open this website
Compare the Triplets
You are viewing a single comment's thread. Return to all comments →
def maxx(a,b): if a==b: return 2 elif a>b: return 0 else: return 1 def compareTriplets(a, b): # Write your code here score=[0]*3 for i in range(0,len(a)): winner=maxx(a[i],b[i]) score[winner]+=1 score.pop() return score