#include #define rep(i,n) for(int i = 0; i < (n); i++) using namespace std; typedef long long ll; int main(){ cin.tie(0); ios::sync_with_stdio(0); int N,M; cin >> N >> M; vector> s(N, vector(M)); rep(i,N)rep(j,M) cin >> s[i][j]; rep(i,N)rep(j,M-3){ if(s[i][j+0] == 'L' && s[i][j+1] == 'O' && s[i][j+2] == 'V' && s[i][j+3] == 'E'){ cout << "YES" << endl; return 0; } } cout << "NO" << endl; }