2 solutions

  • 0
    @ 2025-7-16 17:19:40

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

    int a[15]; int b[15];

    int main() { int x = 0, y = 0, z = 0; for (int i = 1; i <= 10; i++) { cin >> a[i]; } for (int i = 1; i <= 10; i++) { cin >> b[i]; } for (int i = 1; i <= 10; i++) { if (a[i] > b[i]) { x++; } else if (a[i] == b[i]) { y++; } else { z++; } } cout << x << ' ' << y << ' ' << z << endl; if (x > z) { cout << "a>b"; } else if (x < z) { cout << "a<b"; } else { cout << "a=b"; } return 0; }

    Information

    ID
    350
    Time
    1000ms
    Memory
    64MiB
    Difficulty
    4
    Tags
    # Submissions
    74
    Accepted
    34
    Uploaded By