結果
| 問題 |
No.26 シャッフルゲーム
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-06-09 22:26:21 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 31 ms / 5,000 ms |
| コード長 | 201 bytes |
| コンパイル時間 | 276 ms |
| コンパイル使用メモリ | 12,288 KB |
| 実行使用メモリ | 10,240 KB |
| 最終ジャッジ日時 | 2025-01-02 23:55:16 |
| 合計ジャッジ時間 | 1,406 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
n = int(input())
m = int(input())
lst = [0, 0, 0]
lst[n - 1] = 1
for _ in range(m):
p, q = map(int, input().split())
lst[p - 1], lst[q - 1] = lst[q - 1], lst[p - 1]
print(lst.index(1) + 1)