Cod sursa(job #1011107)

Utilizator cypy2474alupei ciprian cypy2474 Data 16 octombrie 2013 10:48:39
Problema Hashuri Scor 30
Compilator cpp Status done
Runda Arhiva educationala Marime 0.41 kb
#include<fstream>
using namespace std;
ifstream f("hashuri.in");
ofstream g("hashuri.out");
int n,x;
bool a[2000000000];
short t;
int main()
{
    int i;

    f>>n;
    for(i=1;i<=n;i++)
        {
            f>>t>>x;
            if(t==1)
                a[x]=1;
            if(t==2)
                a[x]=0;
            if(t==3)
                g<<a[x]<<"\n";

        }

        return 0;
}