CSES - Datatähti 2017 loppu - Results
Submission details
Task:Sukujuhla
Sender:Pohjantahti
Submission time:2017-06-22 20:09:49 +0300
Language:C++
Status:READY
Result:19
Feedback
groupverdictscore
#1UNKNOWN0
#2UNKNOWN0
#3UNKNOWN0
Test results
testverdicttimegroup
#1UNKNOWN--1details
#2UNKNOWN--2details
#3UNKNOWN--3details

Code

#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int n, m, k;
vector<int> v;
int q;

int main() {
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    cin >> n >> m >> k;
    if (n != 16) {
        cout << "gg\n";
        return 0;
    }
    int id = -1;
    int sum = 0;
    for (int i = 0; i < 15; ++i) {
        int cur;
        cin >> cur;
        v.push_back(cur);
        if (i == 7) q = cur;
        if (cur == 1) id = i;
        sum += cur;
    }
    if (id == -1) id = 15; // 1 not in list
    int miss = 136-sum;
    v.push_back(miss);
    vector<int> v2;
    for (int i = id; i < 16; ++i) {
        v2.push_back(v[i]);
    }
    for (int i = 0; i < id; ++i) {
        v2.push_back(v[i]);
    }
    for (int i = 0; i < 16; ++i) {
        if (v2[i] == q) {
            if (i%2 == 0) {
                cout << "A\n";
            }
            else cout << "B\n";
            return 0;
        }
    }
    return 0;
}

Test details

Test 1

Group: 1

Verdict: UNKNOWN

input
#!/bin/bash
set -e
OFFSET=$(grep -onam1 '^__DATA_...

correct output
50

user output
(not available)

Test 2

Group: 2

Verdict: UNKNOWN

input
#!/bin/bash
set -e
OFFSET=$(grep -onam1 '^__DATA_...

correct output
50

user output
(not available)

Test 3

Group: 3

Verdict: UNKNOWN

input
#!/bin/bash
set -e
OFFSET=$(grep -onam1 '^__DATA_...

correct output
50

user output
(not available)