using System; using System.Linq; class Program { static void Main() { double[] d = Console.ReadLine().Split().Select(double.Parse).ToArray(); double a = d[0]; double b = d[1]; double x = d[2]; double y = d[3]; double ans = 0; if (a * y > b * x) ans = x * (a + b) / a; else ans = y * (a + b) / b; Console.WriteLine(ans); } }