結果
問題 |
No.486 3 Straight Win(3連勝)
|
ユーザー |
|
提出日時 | 2019-05-01 16:42:40 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 387 bytes |
コンパイル時間 | 574 ms |
コンパイル使用メモリ | 56,292 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-12-31 12:35:19 |
合計ジャッジ時間 | 1,607 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 27 WA * 1 |
ソースコード
#include <iostream> #include <string> using namespace std; int main(){ string St; int x=0,y=0,east=0,west=0; cin>>St; while(1){ if(St[y]=='O'){ east++; west=0; }else{ west++; east=0; } if(east==3){ cout<<"East"<<endl; return 0; } if(west==3){ cout<<"West"<<endl; return 0; } if(y==St.size()){ cout<<"NA"<<endl; return 0; } y++; } }