int main() {
pair<int, int> res;
// check here pair is empty ?
// res = make_pair(1 , 2);
return 0;
}
In the above snippet what is the ideal way to check if a pair has been initilaized or not?
EDIT: As pointed out in some answers below, using the word "uninitialized" is wrong here, to be more specific how do I check if the value has been explicitly set (other than the default constructor)
pair<T, U>instead of the specificpair<int, int>, right?