Time Limit: 1 sec
Rashed hires a taxi from Hatajari to Agrabad. But taxi driver demands too much fare. Then Rashed tells him “I will pay you as the Government prescribed Fare Rules.” Taxi Driver agreed. Rashed knows that 1km fare is N taka. Total distance is D. If taxi waits in jam, it demands 1 taka per minute.
And fare can never be less than 50.
The input file contains several lines. Each line contains 3 integer values N (0 < N <= 100), D (0 < D <= 100), and K (0 <= K <= 9) denoted taka per kilometer, total distance and waiting time in jam in hour respectively. Input is terminated by end of file (EOF).
For each line of input, the output will show the total fare in a separate line.
30 6 2
10 1 0
Inter School & College Programming Contest (ISCPC) 2015
Problem Setter: Md. Rasel Ahmed