# Buns

Very easy

Execution time limit is 1 second

Runtime memory usage limit is 128 megabytes

Huseyn likes buns very much, which are sold at ADA University in building C. It is known that

you can buy one bun for $a$ qəpiks;

you can buy three buns for $b$ qəpiks;

Huseyn wants to buy exactly $n$ buns. What is the least number of qəpiks he should spend?

## Input

Three positive integers $a,b$ and $n$, each is not greater than $10_{9}$.

## Output

Print the least amount of qəpiks that Huseyn should spend to buy exactly $n$ buns.

## Examples

Input #1

Answer #1

Submissions 1K

Acceptance rate 46%