結果
| 問題 |
No.26 シャッフルゲーム
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2021-05-06 15:44:24 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 42 ms / 5,000 ms |
| コード長 | 199 bytes |
| コンパイル時間 | 159 ms |
| コンパイル使用メモリ | 82,328 KB |
| 実行使用メモリ | 54,044 KB |
| 最終ジャッジ日時 | 2024-09-14 07:16:57 |
| 合計ジャッジ時間 | 1,175 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge6 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
N = int(input())
cup = ["x","x","x"]
cup[N-1] = "o"
M = int(input())
for _ in range(M):
P,Q = map(int,input().split())
cup[P-1],cup[Q-1] = cup[Q-1],cup[P-1]
print(cup.index("o")+1)