集合初始化

数组和集合 / 集合(Set)

#include <iostream>
#include <set>
using namespace std;

set<int> intSet {1, 2, 3};
set<string> strSet { "one", "two", "three" };

for (int i : intSet) cout << i << "; ";
cout << endl;
for (string s : strSet) cout << s << "; ";