Submission #1082562

# Submission time Handle Problem Language Result Execution time Memory
1082562 2024-08-31T15:41:47 Z aaaaaarroz Hotter Colder (IOI10_hottercolder) C++17
0 / 100
430 ms 73044 KB
#include "grader.h"

int HC(int N){
   int l=1,r=N;
   int pivot=1;
   while(l<r){
      Guess(pivot);
      int mid=(l+r)/2;
      int res=Guess(mid);
      if(res==0){
         return (pivot+mid)/2;
      }
      else if(res==-1){
         r=mid-1;
      }
      else if(res==1){
         l=mid+1;
      }
   }
   return ((pivot+r)/2);
}
# Verdict Execution time Memory Grader output
1 Incorrect 21 ms 11152 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 21 ms 11100 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 22 ms 11096 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 430 ms 73044 KB Output isn't correct - alpha = 0.000000000000
2 Halted 0 ms 0 KB -