結果
| 問題 |
No.667 Mice's Luck(ネズミ達の運)
|
| コンテスト | |
| ユーザー |
lam6er
|
| 提出日時 | 2025-03-20 21:19:49 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 118 ms / 2,000 ms |
| コード長 | 352 bytes |
| コンパイル時間 | 188 ms |
| コンパイル使用メモリ | 82,292 KB |
| 実行使用メモリ | 76,736 KB |
| 最終ジャッジ日時 | 2025-03-20 21:20:52 |
| 合計ジャッジ時間 | 2,565 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
S = input().strip()
o_count = S.count('o')
x_count = len(S) - o_count
for c in S:
total = o_count + x_count
probability = (o_count / total) * 100 if total != 0 else 0.0
# Ensure that even integers are printed with decimal places
print("{0:.12f}".format(probability))
if c == 'o':
o_count -= 1
else:
x_count -= 1
lam6er