Cod sursa(job #3349181)
| Utilizator | Data | 25 martie 2026 21:01:01 | |
|---|---|---|---|
| Problema | Hashuri | Scor | 70 |
| Compilator | cpp-64 | Status | done |
| Runda | Arhiva educationala | Marime | 0.43 kb |
#include <bits/stdc++.h>
using namespace std;
ifstream fin("hashuri.in");
ofstream fout("hashuri.out");
int main()
{
int q;
fin>>q;
map <int,int> fq;
while(q--)
{
int op,x;
fin>>op>>x;
if(op==1)
fq[x]=1;
else if(op==2)
fq[x]=0;
else
fout<<fq[x]<<"\n";
}
fin.close();
fout.close();
return 0;
}
