QOJ.ac

QOJ

Time Limit: 1 s Memory Limit: 32 MB Total points: 10

#11832. Plane

統計

Byteland Airlines recently extended their aircraft fleet with a new model of a plane. The new acquisition has $ n_{1} $ rows of seats in the business class and $ n_{2} $ rows in the economic class. In the business class each row contains $ k_{1} $ seats, while each row in the economic class has $ k_{2} $ seats.

Write a program which:

  • reads information about available seats in the plane,
  • calculates the sum of all seats available in that plane,
  • writes the result.

Input Format

In the first and only line of the standard input there are four integers $ n_{1}$, $k_{1}$, $n_{2}$ and $k_{2}$ ($1 ≤ n_{1}, k_{1}, n_{2}, k_{2} ≤ 1\,000$), separated by single spaces.

Output Format

The first and only line of the standard output should contain one integer - the total number of seats available in the plane.

Example

Input

2 5 3 20

Output

70