/ SeriousOJ /

Record Detail

Accepted


  
# Status Time Cost Memory Cost
#1 Accepted 1ms 532.0 KiB
#2 Accepted 1ms 532.0 KiB
#3 Accepted 1ms 532.0 KiB
#4 Accepted 1ms 532.0 KiB
#5 Accepted 1ms 328.0 KiB
#6 Accepted 1ms 532.0 KiB
#7 Accepted 1ms 532.0 KiB
#8 Accepted 1ms 324.0 KiB
#9 Accepted 1ms 324.0 KiB
#10 Accepted 1ms 532.0 KiB
#11 Accepted 1ms 364.0 KiB
#12 Accepted 1ms 332.0 KiB
#13 Accepted 1ms 532.0 KiB
#14 Accepted 1ms 532.0 KiB
#15 Accepted 1ms 528.0 KiB

Code

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

#define int        long long int
#define pb         push_back
#define all(x)     x.begin(),x.end()
#define allr(x)    x.rbegin(),x.rend()
#define ii         pair<int,int>
#define endl       '\n'

void pipra(int tc) {
    int x, a, b;
    cin >> x >> a >> b;
    int d1 = abs(x - a);
    int d2 = abs(x - b);
    if(d1 < d2) {
        cout << "7vai" << endl;
    }
    else if(d1 == d2) {
        cout << "mojo" << endl;
    }
    else {
        cout << "3vai" << endl;
    }
}

int32_t main() {
    ios_base::sync_with_stdio(false);
    cin.tie(NULL); cout.tie(NULL);

    int t = 1;
    // cin >> t;
    for(int i = 1 ; i <= t ; i++)
        pipra(i);
    return 0;
}

Information

Submit By
Type
Submission
Problem
P1179 7vai , 3vai or mojo ?
Language
C++17 (G++ 13.2.0)
Submit At
2025-04-11 10:47:38
Judged At
2025-04-11 10:47:38
Judged By
Score
100
Total Time
1ms
Peak Memory
532.0 KiB