結果
| 問題 | No.26 シャッフルゲーム |
| コンテスト | |
| ユーザー |
norioc
|
| 提出日時 | 2024-07-02 21:45:51 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 29 ms / 5,000 ms |
| コード長 | 204 bytes |
| 記録 | |
| コンパイル時間 | 1,450 ms |
| コンパイル使用メモリ | 84,864 KB |
| 実行使用メモリ | 53,120 KB |
| 最終ジャッジ日時 | 2026-03-24 05:41:26 |
| 合計ジャッジ時間 | 1,251 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
N = int(input())
M = int(input())
bs = [False] * 3
bs[N-1] = True
for _ in range(M):
P, Q = map(lambda x: int(x)-1, input().split())
bs[P], bs[Q] = bs[Q], bs[P]
ans = bs.index(True)
print(ans+1)
norioc