1 #include <bits/stdc++.h> 2 using namespace std; 3 4 //此代码顺带实现了一些特别功能 5 int main() 6 { 7 string in, out; 8 9 cin>>out; 10 while (cin>>in && getchar()!='\n') 11 { 12 out = in + " " + out; 13 } 14 out = in + " " + out; 15 16 cout<<out<<endl; 17 18 return 0; 19 }
c++输入任意个数以空格隔开的字符串
猜你喜欢
转载自www.cnblogs.com/hemeiwolong/p/12454674.html
今日推荐
周排行