跳跳跳

TimeLimit:1000MS  MemoryLimit:32768KB
64-bit integer IO format:%I64d
未提交 | 登录后收藏 | 已有34人收藏了本题
Problem Description
There are \(n\) kids and they want to know who can jump the farthest. For each kid, he can jump three times and the distance he jumps is maximum distance amount all the three jump. For example, if the distance of each jump is (10, 30, 20), then the farthest distance he can jump is 30. Given the distance for each jump of the kids, you should find the rank of each kid.
Input
There are multiple test cases. The first line of input contains an integer \(T\ (1 \le T \le 100)\), indicating the number of test cases. For each test case: The first line contains an integer \(n \ (2 \le n \le 3)\), indicating the number of kids. For the next \(n\) lines, each line contains three integers \(a_i, b_i\) and \(c_i\) (\(1 \le a_i, b_i, c_i, \le 300\)), indicating the distance for each jump of the \(i\)-th kid. It's guaranteed that the final rank of each kid won't be the same (ie. the farthest distance each kid can jump won't be the same).
Output
For each test case, you should output a single line contain \(n\) integers, separated by one space. The \(i\)-th integer indicating the rank of \(i\)-th kid.
SampleInput
2
3
10 10 10
10 20 30
10 10 20
2
3 4 1
1 2 1
SampleOutput
3 1 2
1 2
Submit
题目统计信息详细
总AC数800
通过人数675
尝试人数746
总提交量2259
AC率29.88%
AC该题后可以添加标签
贴完标签可以获得20ACB。
并且可以获得本题所有提交代码查看权限。
点击标题可以显示标签。
如果你还没认真思考过这题,请不要查看标签
如果您已经通过了该题,请务为该题贴上标签

T^T Online Judge

[BUG反馈] [FAQ] [闽ICP备17026590号-1]
当前版本:3.24 系统时间: