Submission #357777

#TimeUsernameProblemLanguageResultExecution timeMemory
357777idk321Hotter Colder (IOI10_hottercolder)C++11
25 / 100
636 ms8228 KiB
#include "grader.h" #include <bits/stdc++.h> using namespace std; int HC(int n){ int a = 1; int b = n; while (b - 1 > a) { int mid = (a + b) / 2; Guess(mid); int q = Guess(mid + 1); if (q == 1) { a = mid; } else { b = mid; } } int q1 = Guess(a); int q2 = Guess(b); if (q2 == 1) return b; return a; }

Compilation message (stderr)

hottercolder.cpp: In function 'int HC(int)':
hottercolder.cpp:24:9: warning: unused variable 'q1' [-Wunused-variable]
   24 |     int q1 = Guess(a);
      |         ^~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...