Limits 1s, 512 MB

Elon Musk often asks a question “Do you think I'm insane?”. We don't know right? But we all know that Elon Musk is planning to colonize Mars. But how much it will cost to travel to Mars for a person? This is a hard question to answer.

Elon Musk wants to inspire young people to go and colonize Mars. And he also wants to choose people with less weight. So he plans to fix the cost in a way so that young and people with less weight have to pay less. He will take the age and weight of a person and calculate his Cost according to the following formula:

Cost = (X * age) + (X * weight)

Here X is a favorite number of Elon Musk.

Input

Input will contain three integer numbers Age, Weight and X (1 ≤ Age, Weight, X ≤ 1000).

Output

Print only one integer, the cost according to the formula.

Sample

InputOutput
2 5 3
21

Submit

Login to submit.

Statistics

96% Solution Ratio
Mehedi_MithunEarliest, Apr '19
Mehedi_MithunFastest, 0.0s
atiq_143Lightest, 0 B
touhidurrrShortest, 28B
Toph uses cookies. By continuing you agree to our Cookie Policy.