map:
if (umap.find(key) != umap.end()) {
cout << "Current key exists." << endl;
}
set:
if (uset.find(key) != uset.end()) {
cout << "Current key exists." << endl;
}
map:
if (umap.find(key) != umap.end()) {
cout << "Current key exists." << endl;
}
set:
if (uset.find(key) != uset.end()) {
cout << "Current key exists." << endl;
}