Advertisement
Rtyrewyger123

Untitled

Apr 27th, 2020
274
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. # include < iostream >
  2. # include < map >
  3. #include < utility >
  4.  
  5. int main()
  6. {
  7. std::map < int, int > m1;
  8. std::map < int, int > m2(m1);
  9. std::map < int, int > m3 = m1;
  10.  
  11. typedef struct std::pair < int, int > PAIR;
  12. std::map < int, int > m1;
  13. m1.insert(PAIR(0, 10));
  14. m1.insert(PAIR(1, 20));
  15. std::map < int, int > m2(m1.begin(), m1.end());
  16. system("pause");
  17. return 0;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement