結果
| 問題 |
No.436 ccw
|
| コンテスト | |
| ユーザー |
Yut176
|
| 提出日時 | 2016-11-11 18:31:48 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 3 ms / 2,000 ms |
| コード長 | 415 bytes |
| コンパイル時間 | 582 ms |
| コンパイル使用メモリ | 72,984 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-11-25 08:18:42 |
| 合計ジャッジ時間 | 1,491 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 24 |
ソースコード
#include<iostream>
#include<algorithm>
#include<cstdio>
#include<cstdlib>
#include<vector>
#include<map>
#include<queue>
#include<string>
#include<sstream>
#include<cmath>
#include<numeric>
using namespace std;
int main(){
string s;
cin >> s;
int cnt = 0;
for(int i=0; i<s.size(); i++){
if( s[i] != 'c' ) break;
cnt++;
}
cout << min( cnt - 1, (int)(s.size() - cnt) ) << endl;
return 0;
}
Yut176