結果
| 問題 |
No.1199 お菓子配り-2
|
| コンテスト | |
| ユーザー |
convexineq
|
| 提出日時 | 2021-05-11 02:56:10 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 184 ms / 1,000 ms |
| コード長 | 186 bytes |
| コンパイル時間 | 859 ms |
| コンパイル使用メモリ | 82,304 KB |
| 実行使用メモリ | 76,160 KB |
| 最終ジャッジ日時 | 2024-09-21 09:01:22 |
| 合計ジャッジ時間 | 12,834 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 45 |
ソースコード
n,m = map(int,input().split())
INF = 10**18
p, q = 0,-INF
for _ in range(n):
x = sum(map(int,input().split()))
pp = max(p,q-x)
qq = max(q,p+x)
p,q = pp,qq
print(max(p,q))
convexineq