#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main()
{
int testi;
vector<int> test;
while(cin >> testi)
test.push_back(testi);
for(vector<int>::size_type t1 = 0; t1 != test.size(); t1++){
for(vector<int>::size_type t2 = 0; t2 != test.size(); t2++){
}}
for(vector<int>::const_iterator iter1 = text.begin(); iter1 != text.end(); iter1++){
for(vector<int>::const_iterator iter2 = text.begin(); iter2 != text.end(); iter2++);
cout<< *iter1 << " " << *iter2 << " ";
}
return 0;
}
Error
F:\计算机\编程\C++\Test\try_vector_arr\s.cpp(17) : error C2065: 'text' : undeclared identifier
F:\计算机\编程\C++\Test\try_vector_arr\s.cpp(17) : error C2228: left of '.begin' must have class/struct/union type
F:\计算机\编程\C++\Test\try_vector_arr\s.cpp(17) : error C2228: left of '.end' must have class/struct/union type
F:\计算机\编程\C++\Test\try_vector_arr\s.cpp(18) : error C2228: left of '.begin' must have class/struct/union type
F:\计算机\编程\C++\Test\try_vector_arr\s.cpp(18) : error C2228: left of '.end' must have class/struct/union type
执行 cl.exe 时出错.
侃侃无极
潇湘沐
相关分类