110 条题解

  • -5
    @ 2026-8-8 11:41:29

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

    int main() { int n, m[35]; cin >> n; for (int i = 0; i < n; i++) { cin >> m[i]; if (m[i] % 2 != 0) { cout << m[i] << " " ; } } cout << endl; for (int j = 0; j < n ; j++) { if (m[j] % 2 == 0) { cout << m[j] << " " ; } } return 0; }

    这题不是P1的题解,是A1158的。

信息

ID
115
时间
1000ms
内存
32MiB
难度
7
标签
递交数
2068
已通过
510
上传者