1 条题解

  • 0
    @ 2025-7-12 16:20:53

    #include <bits/stdc++.h> using namespace std;

    int main() { int a[1000], n, x, v = 0, j; cin >> n; for (int i = 0; i < n; i++) { cin >> x; if (x % 2 == 1) a[v++] = x; } sort(a, a + v); for (int j = 0; j < v; j++) { cout << a[j] ; if (j != v - 1) cout << ","; }

    return 0;
    

    }

    • 1

    信息

    ID
    356
    时间
    1000ms
    内存
    256MiB
    难度
    4
    标签
    递交数
    57
    已通过
    28
    上传者