Submission #317293

#TimeUsernameProblemLanguageResultExecution timeMemory
317293seedkinHotter Colder (IOI10_hottercolder)C11
0 / 100
10095 ms116728 KiB
#include "grader.h" int HC(int N){ int low = 1; int high = N; int g; int h; while ( high - low <= 1 ) { g = Guess(low); h = Guess(high); if(h == 1) { low = (low + high) / 2; } else if (h == -1) { high = (low + high) / 2; } else { return (low + high) / 2; } } g = Guess(low); h = Guess(high); if(h == 1) { return high; } else if (h == -1) { return low; } }

Compilation message (stderr)

hottercolder.c: In function 'HC':
hottercolder.c:7:8: warning: variable 'g' set but not used [-Wunused-but-set-variable]
    7 |    int g;
      |        ^
hottercolder.c:30:1: warning: control reaches end of non-void function [-Wreturn-type]
   30 | }
      | ^
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...