#include "Joi.h"
#include<bits/stdc++.h>
using namespace std;
void Joi(int _N, int _M, int _A[], int _B[], long long _X, int _T) {
int n = _N;
int m = _M;
long long x = _X;
for(int i = 0; i < n; ++i) {
int j = i%60;
// if(i >= 60) {
// cout << "y : " << j << ' ' << (x >> j & 1) << "\n";
// }
MessageBoard(i, (x >> j & 1));
}
}
#include "Ioi.h"
#include<bits/stdc++.h>
using namespace std;
int n, m, start;
int a[10005];
long long Ioi(int _N, int _M, int _A[], int _B[], int _P, int _V, int _T) {
n = _N;
m = _M;
start = _P;
a[start] = _V;
int num = start/60;
int L = num*60, R = min(n, (L+1)*60)-1;
//cout << "x : " << L << ' ' << R << ' ' << _V << "\n";
while(start<R) {
start++;
a[start] = Move(start);
}
while(start>L) {
start--;
a[start] = Move(start);
}
long long ans = 0;
for(int i = L; i <= R; ++i) {
if(a[i]) {
ans |= (1ll << (i-L));
}
}
return ans;
}
Compilation message
Joi.cpp: In function 'void Joi(int, int, int*, int*, long long int, int)':
Joi.cpp:8:8: warning: unused variable 'm' [-Wunused-variable]
8 | int m = _M;
| ^
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
0 ms |
800 KB |
Wrong Answer [7] |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
13 ms |
2324 KB |
Wrong Answer [7] |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
788 KB |
Output is correct |
2 |
Correct |
0 ms |
784 KB |
Output is correct |
3 |
Incorrect |
1 ms |
788 KB |
Wrong Answer [7] |
4 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
16 ms |
2324 KB |
Wrong Answer [7] |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
12 ms |
2340 KB |
Wrong Answer [7] |
2 |
Halted |
0 ms |
0 KB |
- |