6 solutions

  • -1
    @ 2025-7-12 16:17:43

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

    int main() { int a[3]; cin >> a[0] >> a[1] >> a[2]; sort(a, a + 3); if (a[0]*a[0] + a[1] == a[2]*a[2]) { cout << a[2]*a[2]; } else cout << a[1]*a[1] + a[2]*a[2]; return 0; }

    Information

    ID
    359
    Time
    1000ms
    Memory
    64MiB
    Difficulty
    2
    Tags
    # Submissions
    52
    Accepted
    31
    Uploaded By