![]() |
#2
rjsp2011-01-22 08:20
|
请问 想要把一篇文章读入vector中,如下
vector<string> passage;
string x;
cout<<"Please input one passage:"<<endl;
while(cin>>x)
passage.push_back(x);
但是用cmd运行时,怎么才能使系统知道文章已经结束,有什么比较简单的方法吗?
谢了