結果
| 問題 |
No.700 LOVE
|
| コンテスト | |
| ユーザー |
MATSUMAT
|
| 提出日時 | 2018-10-07 22:04:05 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 426 bytes |
| コンパイル時間 | 1,492 ms |
| コンパイル使用メモリ | 166,872 KB |
| 実行使用メモリ | 6,824 KB |
| 最終ジャッジ日時 | 2024-10-12 14:19:05 |
| 合計ジャッジ時間 | 2,136 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 WA * 1 |
| other | AC * 8 WA * 8 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
int main(){
long long n,m;
string s,ans="NO";
cin >> n >> m;
for(int i=0;i<n;i++){
cin >> s;
int cnt=0;
for(int i=0;i<m;i++){
if(s[i]=='L') cnt=1;
if(s[i]=='O' and cnt==1) cnt++;
else cnt=0;
if(s[i]=='V' and cnt==2) cnt++;
else cnt=0;
if(s[i]=='E' and cnt==3) ans="YES";
else cnt=0;
}
}
cout << ans << endl;
}
MATSUMAT