QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#228201 | #7638. Lake | ucup-team055# | WA | 1ms | 3592kb | C++20 | 328b | 2023-10-28 13:09:18 | 2023-10-28 13:09:18 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
ll ceildiv(ll a, ll b) { return a / b + (a % b && (a ^ b) >= 0); }
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
int n, m;
cin >> n >> m;
ll c = max(ceildiv(n, 3), ceildiv(m, 4));
cout << c * 2 - 1 << "\n";
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 1ms
memory: 3428kb
input:
1 1
output:
1
result:
ok single line: '1'
Test #2:
score: 0
Accepted
time: 0ms
memory: 3536kb
input:
1 4
output:
1
result:
ok single line: '1'
Test #3:
score: 0
Accepted
time: 0ms
memory: 3420kb
input:
5 5
output:
3
result:
ok single line: '3'
Test #4:
score: 0
Accepted
time: 0ms
memory: 3420kb
input:
4 4
output:
3
result:
ok single line: '3'
Test #5:
score: 0
Accepted
time: 0ms
memory: 3360kb
input:
3 4
output:
1
result:
ok single line: '1'
Test #6:
score: 0
Accepted
time: 0ms
memory: 3584kb
input:
8 12
output:
5
result:
ok single line: '5'
Test #7:
score: -100
Wrong Answer
time: 1ms
memory: 3592kb
input:
12 8
output:
7
result:
wrong answer 1st lines differ - expected: '5', found: '7'