QOJ.ac
QOJ
The 2nd Universal Cup Finals is coming! Check out our event page, schedule, and competition rules!
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#649827 | #7779. Swiss Stage | KIRITO1211 | AC ✓ | 0ms | 3728kb | C++23 | 860b | 2024-10-18 10:50:35 | 2024-10-18 10:50:43 |
Judging History
answer
#pragma GCC optimize("Ofast")
#pragma GCC optimize("O3,unroll-loops")
//#pragma GCC target("avx2,bmi,bmi2,lzcnt,popcnt")
#include <bits/stdc++.h>
//#define int long long
using ll = long long;
using i64 = long long;
const int mod = 1e9 + 7;
// #define DEBUG
// 线段树合并信息
void solve() {
int x, y;
std::cin >> x >> y;
if(y == 2){
std::cout<<(3 - x) * 2;
}
else{
if(x == 2)std::cout<<2;
else if(x == 1)std::cout<<3;
else std::cout<<4;
}
}
signed main() {
std::ios::sync_with_stdio(false);
std::cin.tie(0);
std::cout<<std::fixed<<std::setprecision(10);
int t = 1;
// int res = 0;
// for(int i = 1;i <= 1145;i++) res |= i;
// std::cerr<<res<<'\n';
//std::cin>>t;
while (t--) {
solve();
}
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 0ms
memory: 3528kb
input:
0 1
output:
4
result:
ok 1 number(s): "4"
Test #2:
score: 0
Accepted
time: 0ms
memory: 3648kb
input:
1 2
output:
4
result:
ok 1 number(s): "4"
Test #3:
score: 0
Accepted
time: 0ms
memory: 3656kb
input:
0 0
output:
4
result:
ok 1 number(s): "4"
Test #4:
score: 0
Accepted
time: 0ms
memory: 3528kb
input:
0 2
output:
6
result:
ok 1 number(s): "6"
Test #5:
score: 0
Accepted
time: 0ms
memory: 3704kb
input:
1 0
output:
3
result:
ok 1 number(s): "3"
Test #6:
score: 0
Accepted
time: 0ms
memory: 3728kb
input:
1 1
output:
3
result:
ok 1 number(s): "3"
Test #7:
score: 0
Accepted
time: 0ms
memory: 3676kb
input:
2 0
output:
2
result:
ok 1 number(s): "2"
Test #8:
score: 0
Accepted
time: 0ms
memory: 3704kb
input:
2 1
output:
2
result:
ok 1 number(s): "2"
Test #9:
score: 0
Accepted
time: 0ms
memory: 3680kb
input:
2 2
output:
2
result:
ok 1 number(s): "2"
Extra Test:
score: 0
Extra Test Passed