/ SeriousOJ /

Record Detail

Wrong Answer


  
# Status Time Cost Memory Cost
#1 Accepted 1ms 356.0 KiB
#2 Wrong Answer 5ms 724.0 KiB
#3 Wrong Answer 5ms 580.0 KiB

Code

#include <bits/stdc++.h>
using namespace std;
#define endl '\n'
#define ll long long int
#define lld long long double
#define ull unsigned long long

void solve(){
    ll a, b, c;
    cin >> a >> b >> c;
    vector <ll> lst = {a,b,c};
    sort(lst.begin(), lst.end());
    if (a == b && b == c){
        cout << 0 << endl;
    }
    else if (lst[0] == lst[1] || lst[1] == lst[2]){
        cout << 1 << endl;
    }
    else if (lst[0] != lst[1] && lst[1] != lst[2] ){
        cout << 2 << endl;
    }
}

int main(){
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    int t;
    cin >> t;
    while(t--){
        solve();
    }
}

Information

Submit By
Type
Submission
Problem
P1061 Bring equality
Contest
Brain Booster #4
Language
C++20 (G++ 13.2.0)
Submit At
2024-07-14 15:54:32
Judged At
2024-11-11 03:25:15
Judged By
Score
10
Total Time
5ms
Peak Memory
724.0 KiB