結果
問題 | No.700 LOVE |
ユーザー |
![]() |
提出日時 | 2018-06-15 22:21:11 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 2,000 ms |
コード長 | 335 bytes |
コンパイル時間 | 1,595 ms |
コンパイル使用メモリ | 168,112 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-07-22 23:13:23 |
合計ジャッジ時間 | 2,323 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 16 |
ソースコード
#include "bits/stdc++.h"using namespace std;int main() {int H; int W;while (~scanf("%d%d", &H, &W)) {bool ans = false;for (int i = 0; i < H; ++ i) {char buf[101];scanf("%s", buf);string row = buf;for (int j = 0; j <= W - 4; ++ j)ans |= row.substr(j, 4) == "LOVE";}puts(ans ? "YES" : "NO");}}