Pagini recente » Cod sursa (job #2736442) | Cod sursa (job #1500500) | Cod sursa (job #2258498) | Diferente pentru problema/salsa intre reviziile 6 si 14 | Cod sursa (job #2721316)
#include <iostream>
#include <fstream>
#include <unordered_map>
using namespace std;
ifstream fin("hashuri.in");
ofstream fout("hashuri.out");
int q;
unordered_map <int, bool> M;
int main()
{
fin >> q;
while(q--)
{ int type, x;
fin >> type >> x;
if(type == 1)
M[x] = 1;
else if(type == 2)
M[x] = 0;
else
fout << M[x] << '\n';
}
return 0;
}