greetings
#include <iostream>
#include <string>
#include <utility>
using namespace std;
int main(int argc, char** argv) {
pair<string, string> myPair_year("2016", "8");
pair<string, string> myPair_greetings("Hello", "GitHub!");
pair<int, string> myPair_great(2016, "Congratulations!");
cout << "*****************************************" << endl;
cout << "Year: " + myPair_year.first + ", " + "Month: " + myPair_year.second << endl;
cout << myPair_greetings.first + " " + myPair_greetings.second << endl;
cout << "*****************************************" << endl;
cout << myPair_great.first << " year! " << myPair_great.second << endl;
return 0;
}
result:
*****************************************
Year: 2016, Month: 8
Hello GitHub!
*****************************************
2016 year! Congratulations!
π πΈ π· π πΉ π» πΊ π π π πΏ π π΅ π΄ π² π³ π° π± πΌ