一、打印vector内容测试代码 #include<iostream> #include<vector> using namespace std; int main(int argc, char* argv[]) { vector<int> vec(10); // 10 zero-initialized elements for (int i = 0; i < vec.size()