为什么只有40分??

P1271 【深基9.例1】选举学生会

这是我写的: ``` #define _CRT_SECURE_NO_WARNINGS #include <math.h> #include<iostream> #include<cstdio> #include<algorithm> #include<string> using namespace std; int main() { long int nums, i, n, s=0, j; int a[1000]; cin >> n>>nums; for (i = 0; i <nums; i++) { cin >> s; a[i] = s; } sort(a, a + nums); for(j=0;j<nums;j++) cout << a[j]<<" "; return 0; } ```
by xuyuteng12345 @ 2024-04-20 21:31:08


人家是python
by Hhy140516 @ 2024-05-04 14:19:28


|