Pagini recente » Diferente pentru problema/tequila intre reviziile 137 si 138 | Monitorul de evaluare | Cod sursa (job #2167020) | Diferente pentru problema/tequila intre reviziile 28 si 144 | Cod sursa (job #1389788)
#include<bits/stdc++.h>
#define mp make_pair
using namespace std;
map <int,int > M;
int main()
{
int T,x,y;
freopen ("hashuri.in","r",stdin);
freopen ("hashuri.out","w",stdout);
scanf("%d", &T);
while(T--)
{
scanf("%d%d", &x,&y);
if(x==1) M[y]++;
if(x==2) M[y]--;
if(x==3)
if(M[y]) printf("1\n");
else printf("0\n");
}
return 0;
}