結果

問題 No.852 連続部分文字列
ユーザー tempura_pptempura_pp
提出日時 2019-07-26 21:20:29
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 628 ms / 3,153 ms
コード長 185 bytes
コンパイル時間 343 ms
コンパイル使用メモリ 87,132 KB
実行使用メモリ 78,056 KB
最終ジャッジ日時 2023-09-15 00:29:48
合計ジャッジ時間 11,375 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 72 ms
71,516 KB
testcase_01 AC 71 ms
71,240 KB
testcase_02 AC 73 ms
71,476 KB
testcase_03 AC 72 ms
71,288 KB
testcase_04 AC 72 ms
71,544 KB
testcase_05 AC 75 ms
75,812 KB
testcase_06 AC 74 ms
75,852 KB
testcase_07 AC 77 ms
75,712 KB
testcase_08 AC 73 ms
71,388 KB
testcase_09 AC 73 ms
71,188 KB
testcase_10 AC 75 ms
75,648 KB
testcase_11 AC 71 ms
71,532 KB
testcase_12 AC 76 ms
75,620 KB
testcase_13 AC 86 ms
76,316 KB
testcase_14 AC 82 ms
75,932 KB
testcase_15 AC 91 ms
76,384 KB
testcase_16 AC 84 ms
76,468 KB
testcase_17 AC 90 ms
76,380 KB
testcase_18 AC 89 ms
76,384 KB
testcase_19 AC 78 ms
75,928 KB
testcase_20 AC 86 ms
76,252 KB
testcase_21 AC 90 ms
76,464 KB
testcase_22 AC 87 ms
76,468 KB
testcase_23 AC 86 ms
76,396 KB
testcase_24 AC 85 ms
76,392 KB
testcase_25 AC 85 ms
76,372 KB
testcase_26 AC 89 ms
76,388 KB
testcase_27 AC 84 ms
76,520 KB
testcase_28 AC 88 ms
76,376 KB
testcase_29 AC 91 ms
76,440 KB
testcase_30 AC 81 ms
76,104 KB
testcase_31 AC 91 ms
76,332 KB
testcase_32 AC 98 ms
76,424 KB
testcase_33 AC 438 ms
77,948 KB
testcase_34 AC 434 ms
77,824 KB
testcase_35 AC 434 ms
77,904 KB
testcase_36 AC 433 ms
78,040 KB
testcase_37 AC 439 ms
77,908 KB
testcase_38 AC 426 ms
77,968 KB
testcase_39 AC 614 ms
78,056 KB
testcase_40 AC 452 ms
77,952 KB
testcase_41 AC 444 ms
77,976 KB
testcase_42 AC 628 ms
77,856 KB
testcase_43 AC 447 ms
77,824 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

S=input()
N=len(S)
sum=13*N*(N+1)
for c in range(ord('a'),ord('z')+1):
    cnt=0
    for i in S:
        if i==chr(c) : cnt=0
        else : cnt+=1
        sum-=cnt
print(2*sum/N/(N+1))
0