結果

問題 No.1994 Confusing Name
ユーザー 👑 H20H20
提出日時 2022-07-01 21:49:43
言語 PyPy3
(7.3.15)
結果
TLE  
実行時間 -
コード長 335 bytes
コンパイル時間 334 ms
コンパイル使用メモリ 87,376 KB
実行使用メモリ 504,348 KB
最終ジャッジ日時 2023-08-17 09:21:52
合計ジャッジ時間 7,027 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 150 ms
81,556 KB
testcase_01 AC 150 ms
81,384 KB
testcase_02 AC 152 ms
81,508 KB
testcase_03 AC 147 ms
80,084 KB
testcase_04 AC 145 ms
80,280 KB
testcase_05 AC 182 ms
95,172 KB
testcase_06 AC 232 ms
105,584 KB
testcase_07 AC 164 ms
86,480 KB
testcase_08 AC 218 ms
101,196 KB
testcase_09 AC 235 ms
109,964 KB
testcase_10 AC 197 ms
101,020 KB
testcase_11 AC 193 ms
100,876 KB
testcase_12 TLE -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
testcase_24 -- -
testcase_25 -- -
testcase_26 -- -
testcase_27 -- -
testcase_28 -- -
testcase_29 -- -
testcase_30 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

import string
import collections
N = int(input())
S = []
CA = collections.Counter()
for _ in range(N):
    S.append(input())
alphabets = list(string.ascii_lowercase)
for s in S:
    s = 'a'+s+'a'
    for i in range(1,len(s)-1):
        for a in alphabets:
            CA[s[:i]+a+s[i+1:]]+=1
for s in S:
    print(CA['a'+s+'a']-len(s))
0