Sets-STL

  • + 0 comments

    include

    include

    include

    include

    include

    include

    using namespace std;

    int main() { /* Enter your code here. Read input from STDIN. Print output to STDOUT */
    int n,x,y; cin>>n; sets; for(int i=0;i>x>>y; if(x==1) s.insert(y); else if(x==2) s.erase(y); else{ set::iterator itr = s.find(y); if(itr!=s.end()) cout<<"Yes"<

    }
    return 0;
    

    }