結果

問題 No.667 Mice's Luck(ネズミ達の運)
ユーザー lloyzlloyz
提出日時 2022-07-19 21:22:45
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 209 ms / 2,000 ms
コード長 251 bytes
コンパイル時間 521 ms
コンパイル使用メモリ 10,768 KB
実行使用メモリ 9,060 KB
最終ジャッジ日時 2023-09-14 18:09:42
合計ジャッジ時間 3,512 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,908 KB
testcase_01 AC 15 ms
7,804 KB
testcase_02 AC 15 ms
7,796 KB
testcase_03 AC 15 ms
8,008 KB
testcase_04 AC 17 ms
7,868 KB
testcase_05 AC 34 ms
8,152 KB
testcase_06 AC 113 ms
8,580 KB
testcase_07 AC 209 ms
9,060 KB
testcase_08 AC 130 ms
8,972 KB
testcase_09 AC 128 ms
8,848 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

S = list(input())

n = len(S)
C = [0, 0]
for i in range(n):
    if S[i] == 'o':
        C[0] += 1
    else:
        C[1] += 1
for i in range(n):
    print(100.0 * C[0] / (C[0] + C[1]))
    if S[i] == 'o':
        C[0] -= 1
    else:
        C[1] -= 1
0