#include <iostream>
#include <list>
#include <string>
#include <sstream>
#include <map>
using namespace std;
int main(){
/********* list ********/
list<string> lis;
lis.push_back("hello");
lis.push_back("world");
for (auto it = lis.begin(); it!=lis.end(); it++){
cout << *it << endl;
}
/********** map *********/
map<string, string> maps;
maps.insert(pair<string, string>("color", "red"));
cout << maps.at("color") << endl;
maps["size"] = "big";
cout << maps["size"] << endl;
/********* string **********/
string str;
str += "Hello ";
str += "World !";
//str += 100; //不可以连接数字,会根据其ASCLL码自动转成字符
cout << str << endl;
/******** sstr **********/
stringstream sstr;
sstr << "Hello";
sstr << " ";
sstr << "World";
sstr << 1000; //可以连接数字
sstr << 2.5;
cout << sstr.str() << endl;
system("pause");
return 0;
}