QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#626407 | #5732. Even or Odd | Rebuked | AC ✓ | 1ms | 3700kb | C++20 | 357b | 2024-10-10 08:00:01 | 2024-10-10 08:00:02 |
Judging History
answer
#include <iostream>
#include <vector>
#include <map>
using namespace std;
int main() {
int a;
cin >> a;
if(a==2) cout << "Odd";
else if(a%2 == 0) {
if((a/2)%2 == 1) {
cout << "Odd";
} else {
cout << "Even";
}
}
else if(a%2 == 1) cout << "Either";
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 1ms
memory: 3552kb
input:
1
output:
Either
result:
ok single line: 'Either'
Test #2:
score: 0
Accepted
time: 0ms
memory: 3636kb
input:
2
output:
Odd
result:
ok single line: 'Odd'
Test #3:
score: 0
Accepted
time: 0ms
memory: 3640kb
input:
3
output:
Either
result:
ok single line: 'Either'
Test #4:
score: 0
Accepted
time: 0ms
memory: 3700kb
input:
4
output:
Even
result:
ok single line: 'Even'
Test #5:
score: 0
Accepted
time: 0ms
memory: 3624kb
input:
5
output:
Either
result:
ok single line: 'Either'
Test #6:
score: 0
Accepted
time: 0ms
memory: 3688kb
input:
6
output:
Odd
result:
ok single line: 'Odd'
Test #7:
score: 0
Accepted
time: 0ms
memory: 3696kb
input:
7
output:
Either
result:
ok single line: 'Either'
Test #8:
score: 0
Accepted
time: 0ms
memory: 3632kb
input:
8
output:
Even
result:
ok single line: 'Even'
Test #9:
score: 0
Accepted
time: 0ms
memory: 3640kb
input:
9
output:
Either
result:
ok single line: 'Either'
Test #10:
score: 0
Accepted
time: 0ms
memory: 3692kb
input:
10
output:
Odd
result:
ok single line: 'Odd'