結果
| 問題 | No.2925 2-Letter Shiritori |
| コンテスト | |
| ユーザー |
hibit_at
|
| 提出日時 | 2024-10-12 15:39:52 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 461 bytes |
| 記録 | |
| コンパイル時間 | 997 ms |
| コンパイル使用メモリ | 20,824 KB |
| 実行使用メモリ | 40,640 KB |
| 平均クエリ数 | 17.33 |
| 最終ジャッジ日時 | 2026-04-29 17:12:59 |
| 合計ジャッジ時間 | 4,891 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 2 |
| other | AC * 1 RE * 9 |
ソースコード
from string import ascii_lowercase
a = ascii_lowercase
from collections import defaultdict
mp = defaultdict(list)
for s in a:
for t in a:
mp[s].append(s+t)
alpha = input()
while True:
for candidate in mp[alpha]:
tail = candidate[1]
if len(mp[tail]):
print('?',mp[alpha].pop())
break
res = input()
if res == '! WIN':
exit()
content = res.split()[1]
alpha = content[1]
hibit_at