文章
59
粉丝
0
获赞
361
访问
44.2k
#include <bits/stdc++.h>
using namespace std;
bool cmp(const string &x,const string &y)
{
return x<y;
}
int main()
{
int N;
cin>>N;
string s;
vector<string> list;
for(int i=0;i<N;i++)
{
cin>>s;
list.push_back(s);
}
sort(list.begin(),list.end(),cmp);
for(int i=0;i<N;i++)
{
cout<<list[i]<<endl;
}
return 0;
}
登录后发布评论
暂无评论,来抢沙发