Answers for "c++ return value of set insert"

C++
0

c++ return value of set insert

set<int> st;
auto p = st.insert(2);
// p.first - iterator to the inserted element
// p.second - true if 2 don't exists in the set otherwise false
Posted by: Guest on March-13-2021

Browse Popular Code Answers by Language