题解 | 最厉害的学生

最厉害的学生

https://www.nowcoder.com/practice/b6e7a9ca04d8418b805b3b4b7d25b4d4

N = int(input())
a = []
for i in range(N):
    s, c1, c2, c3 = input().split()
    t = int(c1) + int(c2) + int(c3)
    a.append((s, c1, c2, c3, t))
re = max(a, key=lambda x: x[4])
print(f"{re[0]} {re[1]} {re[2]} {re[3]}")

全部评论

相关推荐

评论
2
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务