# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
8238 | 2014-09-07T12:55:57 Z | baneling100 | Cookie Clicker Alpha (GCJ14_cookie) | C++ | 20 ms | 1088 KB |
#include <stdio.h> #define INF 0x7fffffff int T; double C, F, X, V, Time, Ans; int main(void) { int i, j; scanf("%d",&T); for(i=1 ; i<=T ; i++) { scanf("%lf %lf %lf",&C,&F,&X); Ans=INF; Time=0; V=2.0; while(Ans>Time) { if(Ans>Time+X/V) Ans=Time+X/V; Time+=C/V; V+=F; } printf("Case #%d: %.7lf\n",i,Ans); } return 0; }
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 1088 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 20 ms | 1088 KB | Output is correct |