Submission #637471

#TimeUsernameProblemLanguageResultExecution timeMemory
637471as111Coins (IOI17_coins)C++14
Compilation error
0 ms0 KiB
#include <coins.h>
#include <vector>

using namespace std;
vector<int> coin_flips(int b[], int c) {
	int A = 0;
	for (int i = 0; i < 64; i++) {
		A = A ^ (i * b[i]);
	}
	vector<int> flips;
	flips.push_back(c ^ x);
}
int find_coin(int b[]) {
	int X = 0;
	for (int i = 0; i < 64; i++) {
		X = X ^ (i * b[i]);
	}
	return X;
}

Compilation message (stderr)

coins.cpp: In function 'std::vector<int> coin_flips(int*, int)':
coins.cpp:11:22: error: 'x' was not declared in this scope
   11 |  flips.push_back(c ^ x);
      |                      ^
coins.cpp:12:1: warning: no return statement in function returning non-void [-Wreturn-type]
   12 | }
      | ^