제출 #477945

#제출 시각아이디문제언어결과실행 시간메모리
477945ocarimaFootball (info1cup20_football)C++14
0 / 100
42 ms2012 KiB
#include <iostream>
#include <iostream>
#include <bits/stdc++.h>

using namespace std;

#define fastio ios_base::sync_with_stdio(false); cin.tie(0)
#define lli long long int
#define nl "\n"
#define rep(i, a, b) for(lli i = (a); i <= (b); ++i)
#define debugsl(x) cout << #x << " = " << x << ", "
#define debug(x) debugsl(x) << endl
#define debugarr(x, a, b) cout << #x << " = ["; rep(i, a, b){ cout << x[i] << ", "; } cout << "]" << nl

#define MAXN 100003

lli t, n, k, a[MAXN], suma, paridad, pot;

int main()
{
    fastio;
    cin >> t;

    while(t--){
        cin >> n >> k;
        rep(i, 1, n) cin >> a[i];
        pot = 1;
        while (pot <= 1e9){
            suma = 0;
            rep(i, 1, n) suma += a[i] / pot;
            if (suma & 1) break;
            pot <<= 1;
        }
        cout << (suma & 1);
    }

    return 0;
}
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…
#결과 실행 시간메모리채점기 출력
결과를 불러오는 중입니다…