Pagini recente » Cod sursa (job #490734) | Cod sursa (job #1629473) | Cod sursa (job #311593) | Cod sursa (job #2093878) | Cod sursa (job #2931920)
#include <iostream>
#include <map>
#include <fstream>
using namespace std;
ifstream fin("hashuri.in");
ofstream fout("hashuri.out");
int n;
int op, x;
map<int, bool> fr;
int main() {
fin.tie(nullptr);
ios_base::sync_with_stdio(false);
fin >> n;
while (n--) {
fin >> op >> x;
if (op == 1)
fr[x] = true;
else if (op == 2)
fr[x] = false;
else
fout << fr[x] << "\n";
}
}