結果

問題 No.667 Mice's Luck(ネズミ達の運)
ユーザー cande398cande398
提出日時 2018-05-15 02:08:18
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 224 ms / 2,000 ms
コード長 218 bytes
コンパイル時間 154 ms
コンパイル使用メモリ 10,576 KB
実行使用メモリ 12,180 KB
最終ジャッジ日時 2023-09-10 20:56:09
合計ジャッジ時間 2,938 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,856 KB
testcase_01 AC 15 ms
7,780 KB
testcase_02 AC 15 ms
7,844 KB
testcase_03 AC 15 ms
7,812 KB
testcase_04 AC 17 ms
7,800 KB
testcase_05 AC 37 ms
8,128 KB
testcase_06 AC 120 ms
9,320 KB
testcase_07 AC 224 ms
10,532 KB
testcase_08 AC 147 ms
12,180 KB
testcase_09 AC 135 ms
8,984 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

S = input()
L = [0 for _ in range(len(S))]
if S[-1] == 'o':
	L[-1] = 1
for i in range(-2, -len(S)-1, -1):
	if S[i] == 'o':
		L[i] = L[i+1] + 1
	else:
		L[i] = L[i+1]
for i in range(len(S)):
	print(L[i]/(len(S)-i)*100)
0