#include "ant.h"
int mi=1, mx=99999999, md, dap;
int FindK() {
while(1){
md = (mi*4+mx*5)/9;
if(mi==mx) break;
int C = DeliverCount(md);
int nmi=mi, nmx=mx;
nmi = md/(C+1)+1;
if(C) nmx = md/C;
if(mi < nmi) mi = nmi;
if(mx > nmx) mx = nmx;
}
return md;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Partially correct |
3 ms |
252 KB |
Partially correct : C = 31 |
2 |
Partially correct |
3 ms |
356 KB |
Partially correct : C = 30 |
3 |
Correct |
4 ms |
560 KB |
Correct |
4 |
Partially correct |
2 ms |
560 KB |
Partially correct : C = 31 |
5 |
Correct |
3 ms |
560 KB |
Correct |