uva 10905
来源:互联网 发布:海鸥食堂影评 知乎 编辑:程序博客网 时间:2024/06/07 08:45
#include<cstdio>#include<string>#include<cstring>#include<iostream>#include<algorithm>using namespace std;bool cmp(string a,string b){return (b+a)<(a+b); }string str[1000];int main(){int n;while(~scanf("%d",&n)&&n){for(int i=0;i<n;i++)cin>>str[i];sort(str,str+n,cmp);for(int i=0;i<n;i++)cout<<str[i];cout<<endl; }}
阅读全文
0 0
- uva 10905
- uva 10905
- uva----10905
- UVa 10905
- UVa 10905
- uva 10905
- UVA 10905 (13.11.06)
- UVA 10905(为什么)
- uva 10905(排序)
- uva
- UVA
- UVA
- UVA
- uva
- UVA
- UVA
- UVA
- UVA
- 2014基本贪心1005
- mybatis中的#和$的区别
- Red and Black HDU
- Leetcode--Path Sum I,II,III
- 操作系统如何管理CPU资源?细说操作系统进程与多任务模型问题
- uva 10905
- 常用的20条Linux命令
- 遍历ArrayList和遍历Map
- Gym
- 设计模式—职责连模式
- 大话算法之动态规划——初探
- [LeetCode]19. Remove Nth Node From End of List
- awk详解:awk语言及应用
- 深入理解JavaScript系列(28):设计模式之工厂模式