結果
| 問題 |
No.667 Mice's Luck(ネズミ達の運)
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2018-06-14 20:03:06 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 340 bytes |
| コンパイル時間 | 5,854 ms |
| コンパイル使用メモリ | 192,360 KB |
| 最終ジャッジ日時 | 2025-01-05 13:18:21 |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 2 WA * 8 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
int N;
string str;
int main(){
cin >> str;
N = str.size();
int nSafe = 0, n = N;
for (int i = 0; i < N; ++i) nSafe += str[i] == 'o';
for (int i = 0; i < N; ++i){
printf("%.14f\n", double(nSafe)/double(n));
--n; nSafe -= str[i] == 'o';
}
return 0;
}