AtCoder Beginner Contest 176
翻译中…
Problem Statement
翻译中…
Takahashi loves takoyaki - a ball-shaped snack.
翻译中…
With a takoyaki machine, he can make at most $X$ pieces of takoyaki at a time, taking $T$ minutes regardless of the number of pieces to make.
翻译中…
How long does it take to make $N$ takoyaki?
翻译中…
Constraints
翻译中…
$1 \leq N,X,T \leq 1000$- All values in input are integers.
翻译中…
Input
翻译中…
Input is given from Standard Input in the following format:
翻译中…
N X T
翻译中…
Output
翻译中…
Print an integer representing the minimum number of minutes needed to make $N$ pieces of takoyaki.
翻译中…
样例
Input #1
20 12 6
Output #1
12
He can make $12$ pieces of takoyaki in the first $6$ minutes and $8$ more in the next $6$ minutes, so he can make $20$ in a total of $12$ minutes.
Note that being able to make $12$ in $6$ minutes does not mean he can make $2$ in $1$ minute.
Input #2
1000 1 1000
Output #2
1000000
It seems to take a long time to make this kind of takoyaki.
题目信息
题面与样例版权归 AtCoder 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。