ax,ay = map(int,input().split()) bx,by = map(int,input().split()) w = ax + bx h = by-ay katamuki = h/w print(katamuki*ax+ay)