a,b,c,d=input().split() a=int(a) b=int(b) c=int(c) d=int(d) detx=abs(a-c) dety=abs(b-d) if detx>dety: print(detx) else: print(dety)