标签:algorithm turn queue algo ret 练习 输入 print type
基础练习 数列排序
1 #include <iostream> 2 #include <algorithm> 3 #include <cstring> 4 #include <cstdio> 5 #include <cmath> 6 #include <stack> 7 #include <map> 8 #include <queue> 9 10 using namespace std; 11 12 int main() 13 { 14 int n, A[210]; 15 scanf("%d", &n); 16 for(int i = 0; i < n; ++ i) 17 scanf("%d", &A[i]); 18 sort(A, A+n, less<int>()); 19 for (int i = 0; i < n; ++ i) 20 printf("%d ", A[i]); 21 printf("\n"); 22 return 0; 23 }
标签:algorithm turn queue algo ret 练习 输入 print type
原文地址:https://www.cnblogs.com/GetcharZp/p/9033499.html