結果
問題 | No.203 ゴールデン・ウィーク(1) |
ユーザー |
![]() |
提出日時 | 2015-05-16 19:07:21 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 376 bytes |
コンパイル時間 | 1,507 ms |
コンパイル使用メモリ | 159,152 KB |
実行使用メモリ | 6,824 KB |
最終ジャッジ日時 | 2024-11-18 09:18:16 |
合計ジャッジ時間 | 2,472 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 29 |
ソースコード
#include<bits/stdc++.h>using namespace std;int main(){string str;for(int i=0;i<2;i++){string s;cin>>s;str+=s;}int ma=0;int cur=0;while(cur<str.size()){int cnt=0;while(cur<str.size()&&str[cur]=='o')cur++,cnt++;ma=max(ma,cnt);while(cur<str.size()&&str[cur]=='x')cur++;}cout<<ma<<endl;}