first = input() split_first = first.split() N=int(split_first[0]) i=1 ans="NO" while i!=N: word=input() if "LOVE" in word: ans="YES" break else: ans="NO" i+=1 print(ans)