14 lines
358 B
Python
14 lines
358 B
Python
# https://leetcode.com/problems/find-champion-i
|
|
from typing import List
|
|
|
|
class Solution:
|
|
def findChampion(self, grid: List[List[int]]) -> int:
|
|
max_sum = -1
|
|
win = -1
|
|
for i in range(len(grid)):
|
|
curr = sum(grid[i])
|
|
if max_sum < curr:
|
|
win = i
|
|
max_sum = curr
|
|
return win
|
|
|