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