6 solutions

  • 1
    @ 2025-7-7 11:43:28
    #include<bits/stdc++.h>
    using namespace std;
    int main()
    {
        char a,b,c;
        cin>>a>>b>>c;
        if(a==b && b==c) cout<<-1;
        else if(a==b) cout<<c;
        else if(a==c) cout<<b;
        else cout<<a;
        return 0;
    }
    

    Information

    ID
    2369
    Time
    1000ms
    Memory
    256MiB
    Difficulty
    1
    Tags
    (None)
    # Submissions
    88
    Accepted
    35
    Uploaded By