Submission #927247

#TimeUsernameProblemLanguageResultExecution timeMemory
927247vjudge1Hotter Colder (IOI10_hottercolder)C++11
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; int Guess(int); int HC(int n) { for(int i = 1; i <= n; i++) { for(int j = i + 2; j <= n; j++) { Guess(i) if(!Guess(j)) return (j + i) >> 1; } } }

Compilation message (stderr)

hottercolder.cpp: In function 'int HC(int)':
hottercolder.cpp:9:21: error: expected ';' before 'if'
    9 |             Guess(i)
      |                     ^
      |                     ;
   10 |             if(!Guess(j)) return (j + i) >> 1;
      |             ~~       
hottercolder.cpp:13:1: warning: no return statement in function returning non-void [-Wreturn-type]
   13 | }
      | ^