H,M=map(int,input().split()) if H<7 or H==7 and M<30: print("Yes") elif H<8 or H==8 and M<30: print("Late") else: print("No")