# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
31023 |
2017-08-04T17:26:22 Z |
TAMREF |
동전 게임 (KOI15_coin) |
C++11 |
|
19 ms |
2180 KB |
#include <bits/stdc++.h>
using namespace std;
int k,Q,m,n;
int main(){
cin.sync_with_stdio(false);
cin.tie(0);
for(cin>>k>>Q;Q--;){
cin>>m>>n;
if((m>n && m>n+(k-n)/2+1)||(m<=n && n>m+(k-m+1)/2)) puts("0");
else puts("1");
}
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
2180 KB |
Output is correct |
2 |
Correct |
0 ms |
2180 KB |
Output is correct |
3 |
Correct |
0 ms |
2180 KB |
Output is correct |
4 |
Correct |
0 ms |
2180 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
2180 KB |
Output is correct |
2 |
Correct |
0 ms |
2180 KB |
Output is correct |
3 |
Correct |
0 ms |
2180 KB |
Output is correct |
4 |
Correct |
0 ms |
2180 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
2180 KB |
Output is correct |
2 |
Correct |
0 ms |
2180 KB |
Output is correct |
3 |
Correct |
0 ms |
2180 KB |
Output is correct |
4 |
Correct |
9 ms |
2180 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
2180 KB |
Output is correct |
2 |
Correct |
0 ms |
2180 KB |
Output is correct |
3 |
Correct |
16 ms |
2180 KB |
Output is correct |
4 |
Correct |
13 ms |
2180 KB |
Output is correct |
5 |
Correct |
13 ms |
2180 KB |
Output is correct |
6 |
Correct |
19 ms |
2180 KB |
Output is correct |
7 |
Correct |
13 ms |
2180 KB |
Output is correct |
8 |
Correct |
16 ms |
2180 KB |
Output is correct |