618. Fuel consumption
A car needs to consume 1 liter of gasoline for every 12 kilometers. Now tell you the driving speed S (km/h) and driving time T (h) of the car. Please calculate how many liters of gasoline the car consumes during the driving process. .
Input format
There are two lines of input. The first line contains an integer T, which represents the travel time (h).
The second line contains an integer S, which represents the driving speed (km/h).
Output format
The total fuel consumption during driving is output, and the result is kept to three decimal places.
data range
1≤T,S≤109
Input sample:
10
85
Sample output:
70.833
#include <cstdio>
int main()
{
double t, s;
scanf("%lf%lf", &t, &s);
printf("%.3lf", t * s / 12);
return 0;
}