Submission #648016

#TimeUsernameProblemLanguageResultExecution timeMemory
648016dutinmeowCoins (IOI17_coins)C++17
Compilation error
0 ms0 KiB
#include "coins.h" #include <vector> std::vector<int> coin_flips(std::vector<int> b, int c) { int cur = c; for (int i = 0; i < 64; i++) cur ^= b[i] * i; int a[1] = {cur}; return a; } int find_coin(std:vector<int> b) { int cur = 0; for (int i = 0; i < ) cur ^= b[i] * i; return cur; }

Compilation message (stderr)

coins.cpp: In function 'std::vector<int> coin_flips(std::vector<int>, int)':
coins.cpp:9:9: error: could not convert 'a' from 'int [1]' to 'std::vector<int>'
    9 |  return a;
      |         ^
      |         |
      |         int [1]
coins.cpp: At global scope:
coins.cpp:12:18: error: found ':' in nested-name-specifier, expected '::'
   12 | int find_coin(std:vector<int> b) {
      |                  ^
      |                  ::
coins.cpp: In function 'int find_coin(std::vector<int>)':
coins.cpp:14:22: error: expected primary-expression before ')' token
   14 |  for (int i = 0; i < )
      |                      ^
coins.cpp:14:21: error: expected ';' before ')' token
   14 |  for (int i = 0; i < )
      |                     ^~
      |                     ;