#include "coins.h"
using namespace std;
vector<int> coin_flips(vector<int> b, int c)
{
int tmp = 0;
for (int i = 0; i < 64; i++) {
if (b[i]) tmp ^= i;
}
b[tmp ^ c] = !b[tmp ^ c];
return b;
}
int find_coin(vector<int> b)
{
int ans = 0;
for (int i = 0; i < 64; i++) {
if (b[i]) ans ^= i;
}
return ans;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
1112 KB |
WA in grader: invalid flips length |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
1112 KB |
WA in grader: invalid flips length |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
7 ms |
1688 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
1224 KB |
WA in grader: invalid flips length |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Incorrect |
1 ms |
1112 KB |
WA in grader: invalid flips length |
2 |
Halted |
0 ms |
0 KB |
- |