Advertisement
Josif_tepe

Untitled

Jun 8th, 2024
316
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.34 KB | None | 0 0
  1. #include <map>
  2. #include <iostream>
  3. using namespace std;
  4. typedef long long ll;
  5. int main()
  6. {
  7.     map<string, int> mapa;
  8.     mapa["Josif"] = 22;
  9.     mapa["Teo"] = 50;
  10.     mapa["Stefan"] = 20;
  11.  
  12.     for(auto it = mapa.begin(); it != mapa.end(); it++) {
  13.       cout << it->first << " " << it->second << endl;
  14.     }
  15.  
  16.     return 0;
  17. }
  18.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement