답안 #918542

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
918542 2024-01-30T06:21:00 Z nasir_bashirov Coins (IOI17_coins) C++11
0 / 100
2 ms 1116 KB
#include "coins.h"
#include <bits/stdc++.h>
using namespace std;

#define db long double
#define ll long long
#define pii pair<int, int>
#define pll pair<ll, ll>
#define vi vector<int>
#define vl vector<ll>
#define vii vector<pii>
#define vll vector<pll>
// #define endl '\n'
#define all(x) x.begin(), x.end()
#define fastio\
    ios_base::sync_with_stdio(0);\
    cin.tie(0);\
    cout.tie(0)\

vector<int> coin_flips(std::vector<int> b, int c) {
    std::vector<int> flips(1);
    ll xr = c;
    for(int i = 0; i < 63; i++){
        if(b[i]){
            xr ^= (1LL << i);
        }
    }
    flips[xr] = 1 - flips[xr];
    return flips;
}

int find_coin(std::vector<int> b) {
    ll xr = b[0];
    for(int i = 1; i <= 63; i++){
        xr ^= (1LL << i) * b[i];
    }
    return xr;
}
# 결과 실행 시간 메모리 Grader output
1 Runtime error 2 ms 1116 KB Execution killed with signal 11
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Runtime error 2 ms 1116 KB Execution killed with signal 11
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Runtime error 2 ms 1116 KB Execution killed with signal 11
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Runtime error 2 ms 1116 KB Execution killed with signal 11
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Runtime error 2 ms 1116 KB Execution killed with signal 11
2 Halted 0 ms 0 KB -