1 2 3 4 | int a = Int32.Parse(Console.ReadLine()); int b = Int32.Parse(Console.ReadLine()); int z = Math.Max(a, 2*b) + Math.Max(2*a-b, b); Console.WriteLine(z); |
1 2 3 4 | int a = Int32.Parse(Console.ReadLine()); int b = Int32.Parse(Console.ReadLine()); int z = Math.Max(a, 2*b) + Math.Max(2*a-b, b); Console.WriteLine(z); |