S,P,X=input().split() s,p,x=input().split() if P>p: print(S) elif P