結果
| 問題 | No.145 yukiover |
| コンテスト | |
| ユーザー |
37kt_
|
| 提出日時 | 2016-04-27 10:45:50 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 344 bytes |
| 記録 | |
| コンパイル時間 | 893 ms |
| コンパイル使用メモリ | 176,384 KB |
| 実行使用メモリ | 6,400 KB |
| 最終ジャッジ日時 | 2026-04-20 10:44:32 |
| 合計ジャッジ時間 | 4,856 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 9 WA * 11 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
int n;
string s;
int main(){
cin >> n >> s;
int c = 0;
for (int i = 1; i <= 4; i++){
string t("yuki", i);
string u("aaaa", i);
for (int j = 0; j + i <= n; j++){
if (s.substr(j, j + i) > t){
c++;
s.replace(j, i, u);
}
}
}
cout << c << endl;
}
37kt_