Problem coingame
User bribritt
Submission Time 2023-04-03 12:54:07
Score 0
Max Time N/A
Max Memory N/A

Compile Error

coingame.cpp: In function ‘int main()’:
coingame.cpp:12:40: error: no match for ‘operator>>’ (operand types are ‘std::basic_ostream<char>::__ostream_type’ {aka ‘std::basic_ostream<char>’} and ‘int’)
12 | if(N & 1) cout << (N * N - 2 * N - 3) >> 2;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~ ~
| | |
| | int
| std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}
coingame.cpp:12:40: note: candidate: ‘operator>>(int, int)’ <built-in>
12 | if(N & 1) cout << (N * N - 2 * N - 3) >> 2;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
coingame.cpp:12:40: note: no known conversion for argument 1 from ‘std::basic_ostream<char>::__ostream_type’ {aka ‘std::basic_ostream<char>’} to ‘int’
In file included from /usr/include/x86_64-linux-gnu/c+