結果
問題 |
No.1994 Confusing Name
|
ユーザー |
|
提出日時 | 2022-07-01 22:33:08 |
言語 | PyPy3 (7.3.15) |
結果 |
TLE
|
実行時間 | - |
コード長 | 419 bytes |
コンパイル時間 | 283 ms |
コンパイル使用メモリ | 81,664 KB |
実行使用メモリ | 87,808 KB |
最終ジャッジ日時 | 2024-11-26 05:56:36 |
合計ジャッジ時間 | 32,887 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 22 TLE * 6 |
ソースコード
import sys from collections import defaultdict input = lambda: sys.stdin.readline().rstrip() # ----------------------- # n = int(input()) S = [input() for _ in range(n)] st = set(S) alp = 'abcdefghijklmnopqrstuvwxyz' for s in S: ans = 0 for i in range(len(s)): for c in alp: if s[i] == c: continue t = list(s) t[i] = c if ''.join(t) in st: ans += 1 print(ans)