結果
| 問題 | No.26 シャッフルゲーム |
| コンテスト | |
| ユーザー |
toshiro_yanagi
|
| 提出日時 | 2018-09-28 22:14:23 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
AC
|
| 実行時間 | 103 ms / 5,000 ms |
| コード長 | 256 bytes |
| 記録 | |
| コンパイル時間 | 516 ms |
| コンパイル使用メモリ | 20,572 KB |
| 実行使用メモリ | 15,360 KB |
| 最終ジャッジ日時 | 2026-04-28 18:00:53 |
| 合計ジャッジ時間 | 2,556 ms |
|
ジャッジサーバーID (参考情報) |
judge1_1 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
def main():
N = int(input())
M = int(input())
L = 3
cups = [0] * (L + 1)
cups[N] = 1
for i in range(M):
P, Q = map(int, input().split())
cups[P], cups[Q] = cups[Q], cups[P]
print(cups.index(max(cups)))
main()
toshiro_yanagi