#include int main() { int n, m; scanf("%d %d", &n, &m); int i, j; char s[55][55]; for (i = 0; i < n; i++) scanf("%s", s[i]); for (i = 0; i < n; i++) { for (j = 0; j < m - 3; j++) { if (s[i][j] == 'L' && s[i][j + 1] == 'O' && s[i][j + 2] == 'V' && s[i][j + 3] == 'E') { printf("YES\n"); return 0; } } } printf("NO\n"); return 0; }