#include #define rep(i, ss, ee) for (int i = ss; i < ee; ++i) using namespace std; void solve() { int N, M; string s; cin >> N >> M; rep(i, 0, N) { cin >> s; if (s.find("LOVE") != s.npos) { cout << "YES" << endl; return; } } cout << "NO" << endl; } int main() { cin.tie(0); ios::sync_with_stdio(false); solve(); getchar(); }