Sticks
Togrul has four sticks, each with a positive integer length. He can break any of these sticks into multiple smaller sticks, ensuring that each resulting stick also has a positive integer length, and that the sum of these lengths equals the original stick's length.
After breaking the sticks, Togrul will choose four of the resulting sticks to form a rectangle, using each stick as one side of the rectangle. Each side of the rectangle must be made up of exactly one stick.
Togrul aims to create a rectangle with the largest possible area. Your task is to help him determine the maximum area of such a rectangle.
Input
The input consists of a single line with four positive integers a
, b
, c
, d
— representing the lengths of the sticks Togrul initially has (1
⩽ a
, b
, c
, d
⩽ 10^9
).
Output
Output a single integer — the largest possible area of the rectangle that Togrul can form by breaking and rearranging the original sticks.