Submission #1096784

# Submission time Handle Problem Language Result Execution time Memory
1096784 2024-10-05T06:31:34 Z Muhammet Xoractive (IZhO19_xoractive) C++17
Compilation error
0 ms 0 KB
#include <bits/stdc++.h>
#include "interactive.h"

using namespace std;

vector<int> guess(int n) {
	vector <int> ans(n,0);
	for(int i = 1; i <= n; i++){
		int x;
		ask(i);
		cin >> x;
		a[i-1] = x;
	}
	return ans;
}

Compilation message

Xoractive.cpp: In function 'std::vector<int> guess(int)':
Xoractive.cpp:12:3: error: 'a' was not declared in this scope
   12 |   a[i-1] = x;
      |   ^