| # | Problem | Pass Rate (passed user / total user) |
|---|---|---|
| 14730 | I'm Buying |
|
Description
Foxy is the richest among all animals in Taiwan.
One day, he found himself admitted by the greatest school, NTHU, so he wants to buy everyone he knows dinner buffet.
But unfortunately, his worst subject is math, please help him calculate how much money he should prepare for the dinner.
Input
In every testcase, you'll be given 2 positive intergers n and m, meaning that there will be a total of n animals participating the dinner (excluding Foxy), and the buffet would cost m dollars per animal.
1 ≤ n,m ≤ 109
Output
Output the minium amount of money Foxy should bring to the dinner.