結果
| 問題 | No.3196 Unique Nickname |
| コンテスト | |
| ユーザー |
Kude
|
| 提出日時 | 2025-07-11 21:23:01 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 77 ms / 2,000 ms |
| + 551µs | |
| コード長 | 216 bytes |
| 記録 | |
| コンパイル時間 | 244 ms |
| コンパイル使用メモリ | 96,100 KB |
| 実行使用メモリ | 79,500 KB |
| 最終ジャッジ日時 | 2026-07-13 02:58:14 |
| 合計ジャッジ時間 | 2,885 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 20 |
ソースコード
from collections import Counter
n = int(input())
st = [input().split() for _ in range(n)]
c = Counter()
for s, t in st:
c[s] += 1
c[t] += 1
print('Yes' if all(c[s] == 1 or c[t] == 1 for s, t in st) else 'No')
Kude