結果
| 問題 | No.667 Mice's Luck(ネズミ達の運) |
| コンテスト | |
| ユーザー |
troro_kelp
|
| 提出日時 | 2018-03-23 22:36:56 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 745 ms / 2,000 ms |
| コード長 | 463 bytes |
| 記録 | |
| コンパイル時間 | 415 ms |
| コンパイル使用メモリ | 92,400 KB |
| 実行使用メモリ | 7,844 KB |
| 最終ジャッジ日時 | 2026-03-11 02:00:35 |
| 合計ジャッジ時間 | 4,232 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
#include <iostream>
#include <vector>
#include <algorithm>
#include <string>
#include <iomanip>
using namespace std;
string s;
int main() {
cin >> s;
string str = s;
for (int i = 0; i < s.size(); ++i) {
int can = 0, cannot = 0;
for (int j = 0; j < str.size(); ++j) {
if (str[j] == 'o') can++;
else if (str[j] == 'x') cannot++;
}
cout << fixed << (double)can / (double)str.size()*100<< endl;
str = str.substr(1, str.size() - 1);
}
return 0;
}
troro_kelp