So, was learning STL and started off with learning pairs.
my code :-
#include <iostream>
#include <utility>
using namespace std;
int main() {
pair<int, int> p = {1, 3};
cout << p.second;
return 0;
}
in the video I saw, it was working correctly for him.
but in my case this error shows up while compilin -
6 29 C:\Users\ASUS\Documents\C++\vectors.cpp [Error] in C++98 'p' must be initialized by constructor, not by '{...}'