結果
| 問題 | No.548 国士無双 |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-08-10 16:01:55 |
| 言語 | Python3 (3.14.7 + numpy 2.5.2 + scipy 1.18.0 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 96 ms / 2,000 ms |
| + 293µs | |
| コード長 | 435 bytes |
| 記録 | |
| コンパイル時間 | 300 ms |
| コンパイル使用メモリ | 21,340 KB |
| 実行使用メモリ | 15,788 KB |
| 最終ジャッジ日時 | 2026-09-01 09:23:04 |
| 合計ジャッジ時間 | 4,185 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 24 |
ソースコード
from collections import Counter
alp = "abcdefghijklm"
S = input()
chkflg = 0
for x in Counter(list(S)).values():
if x > 2:
print("Impossible")
exit()
elif x == 2:
chkflg += 1
elif chkflg > 1:
print("Impossible")
exit()
if set(list(alp)) == set(list(S)):
for x in list(alp):
print(x)
else:
res = set(list(alp)) - set(list(S))
for x in sorted(res):
print(x)