/ SeriousOJ /

Record Detail

Accepted


  
# Status Time Cost Memory Cost
#1 Accepted 1ms 532.0 KiB
#2 Accepted 29ms 1.02 MiB
#3 Accepted 57ms 1.52 MiB

Code

#ifndef LOCAL
#include <bits/stdc++.h>
#define debug(...)
#endif

using namespace std;
#define int long long
#define cinv(v) for (auto &it:v) cin>>it;
#define coutv(v) for (auto &it:v) cout<< it<<' '; cout<<'\n';

void shelby() {
    int a, b, c;
    cin >> a >> b >> c;
    int rem = max(0LL, (a % 2) + (b % 2) + (c % 2) - 1);
    cout << (a + b + c) - rem << '\n';
}

signed main() {
    cin.tie(0)->sync_with_stdio(0);
    int t = 1;
    cin >> t;
    for (int _ = 1; _ <= t; ++_) {
        // cout << "Case " << _ << ": ";
        shelby();
    }
}

Information

Submit By
Type
Submission
Problem
P1195 B. Palindrome
Contest
Brain Booster #10
Language
C++17 (G++ 13.2.0)
Submit At
2025-06-13 15:43:53
Judged At
2025-06-13 15:43:53
Judged By
Score
100
Total Time
57ms
Peak Memory
1.52 MiB