a=input() b=input() if a>b: print("YES") else: print("NO")