We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
int q;
cin>>q;``
while(q>0)
{
int y, x;
cin>>y>>x;
if(y==1){qX.insert(x);}
if(y==2){qX.erase(x);}
if(y==3){
auto it = qX.find(x);
if(it != qX.end()){cout<<"Yes\n";}
else{cout<<"No\n";}
}
q--;}
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Sets-STL
You are viewing a single comment's thread. Return to all comments →