Submission #119551

# Submission time Handle Problem Language Result Execution time Memory
119551 2019-06-21T11:26:22 Z Plurm Hotter Colder (IOI10_hottercolder) C++11
77 / 100
817 ms 8180 KB
#include "grader.h"
#include <cstdio>
int HC(int N){
    int lo = 1;
    int hi = N;
    while(lo < hi){
        Guess(lo);
        int r = Guess(hi);
        if(r > 0){
            lo = (lo + hi)/2 + 1;
        }else if(r == 0){
            return (lo + hi)/2;
        }else{
            hi = (lo + hi - 1)/2;
        }
    }
    return lo;
}
# Verdict Execution time Memory Grader output
1 Correct 35 ms 1272 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 35 ms 1272 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 28 ms 1272 KB Output is correct
# Verdict Execution time Memory Grader output
1 Partially correct 817 ms 8180 KB Output is partially correct - alpha = 0.068965517241