結果
| 問題 |
No.700 LOVE
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-05-29 18:59:18 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 583 bytes |
| コンパイル時間 | 1,422 ms |
| コンパイル使用メモリ | 166,608 KB |
| 実行使用メモリ | 5,248 KB |
| 最終ジャッジ日時 | 2024-10-15 16:55:23 |
| 合計ジャッジ時間 | 2,321 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 14 WA * 2 |
ソースコード
#include <bits/stdc++.h>
#define rep(i,n) for (int i = 0; i < (n); i ++)
using namespace std;
typedef long long ll;
typedef pair<ll,ll> PL;
typedef pair<int,int> P;
const int INF = 1e9;
const ll MOD = 1e9 + 7;
const double eps = 1e-6;
int main(){
int N,M; cin >> N >> M;
bool flag = false;
rep(i,N){
string S; cin >> S;
rep(j,M - 4) {
if (S.substr(j,4) == "LOVE") {
flag = true;
break;
}
}
if (flag) break;
}
if (flag) cout << "YES" << endl;
else cout << "NO" << endl;
}