QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#228190 | #7638. Lake | ucup-team1883# | WA | 0ms | 3876kb | C++17 | 294b | 2023-10-28 13:08:38 | 2023-10-28 13:08:38 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
int main() {
int a, b;
scanf("%d%d", &a, &b);
int ans = 0;
for (; a != 0 || b != 0; ++ans) {
a -= min(a, 4);
b -= min(b, 4);
if (a > b) a -= min(a, 1);
else b -= min(b, 1);
}
printf("%d\n", 2 * ans - 1);
}
详细
Test #1:
score: 100
Accepted
time: 0ms
memory: 3876kb
input:
1 1
output:
1
result:
ok single line: '1'
Test #2:
score: 0
Accepted
time: 0ms
memory: 3808kb
input:
1 4
output:
1
result:
ok single line: '1'
Test #3:
score: 0
Accepted
time: 0ms
memory: 3760kb
input:
5 5
output:
3
result:
ok single line: '3'
Test #4:
score: -100
Wrong Answer
time: 0ms
memory: 3868kb
input:
4 4
output:
1
result:
wrong answer 1st lines differ - expected: '3', found: '1'