結果
問題 | No.2261 Coffee |
ユーザー | minimum |
提出日時 | 2023-04-07 21:53:31 |
言語 | PyPy3 (7.3.13) |
結果 |
TLE
|
実行時間 | - |
コード長 | 564 bytes |
コンパイル時間 | 548 ms |
コンパイル使用メモリ | 87,004 KB |
実行使用メモリ | 155,996 KB |
最終ジャッジ日時 | 2023-07-26 02:54:29 |
合計ジャッジ時間 | 9,206 ms |
ジャッジサーバーID (参考情報) |
judge14 / judge12 |
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 72 ms
75,968 KB |
testcase_01 | AC | 84 ms
76,524 KB |
testcase_02 | AC | 74 ms
71,572 KB |
testcase_03 | AC | 73 ms
71,280 KB |
testcase_04 | AC | 80 ms
76,512 KB |
testcase_05 | AC | 82 ms
76,708 KB |
testcase_06 | AC | 85 ms
76,632 KB |
testcase_07 | AC | 79 ms
76,268 KB |
testcase_08 | AC | 86 ms
76,636 KB |
testcase_09 | AC | 82 ms
76,704 KB |
testcase_10 | AC | 95 ms
76,856 KB |
testcase_11 | AC | 98 ms
76,460 KB |
testcase_12 | AC | 92 ms
76,740 KB |
testcase_13 | AC | 92 ms
76,492 KB |
testcase_14 | AC | 95 ms
76,692 KB |
testcase_15 | AC | 89 ms
76,792 KB |
testcase_16 | AC | 93 ms
76,676 KB |
testcase_17 | AC | 276 ms
78,944 KB |
testcase_18 | AC | 267 ms
79,172 KB |
testcase_19 | AC | 247 ms
79,016 KB |
testcase_20 | AC | 228 ms
78,720 KB |
testcase_21 | AC | 272 ms
78,992 KB |
testcase_22 | AC | 233 ms
78,896 KB |
testcase_23 | AC | 293 ms
79,120 KB |
testcase_24 | TLE | - |
testcase_25 | -- | - |
testcase_26 | -- | - |
testcase_27 | -- | - |
testcase_28 | -- | - |
testcase_29 | -- | - |
testcase_30 | -- | - |
testcase_31 | -- | - |
testcase_32 | -- | - |
testcase_33 | -- | - |
testcase_34 | -- | - |
testcase_35 | -- | - |
testcase_36 | -- | - |
testcase_37 | -- | - |
testcase_38 | -- | - |
testcase_39 | -- | - |
testcase_40 | -- | - |
testcase_41 | -- | - |
testcase_42 | -- | - |
testcase_43 | -- | - |
testcase_44 | -- | - |
ソースコード
N = int(input()) ls = [list(map(int, input().split())) for _ in range(N)] ls2 = [] for i in range(1 << 5): tmp = [] for j in range(N): s = 0 for k in range(5): if (i >> k) & 1 == 0: s += ls[j][k] else: s -= ls[j][k] tmp.append((s, j)) tmp.sort() ls2.append(tmp[0][1]) ls2.append(tmp[-1][1]) for k in range(N): ans = 0 for i in ls2: s = 0 for j in range(5): s += abs(ls[k][j] - ls[i][j]) ans = max(ans, s) print(ans)