Submission #406715

# Submission time Handle Problem Language Result Execution time Memory
406715 2021-05-18T03:34:18 Z wiwiho Toy Train (IOI17_train) C++14
0 / 100
6 ms 700 KB
#include "train.h"

#include<bits/stdc++.h>

#define printv(a, b) { \
    for(auto pv : a) b << pv << " "; \
    b << "\n"; \
}
#define mp make_pair
#define F first
#define S second
#define iter(a) a.begin(), a.end()
#define lsort(a) sort(iter(a))
#define eb emplace_back

using namespace std;

typedef long long ll;

using pii = pair<int, int>;

const ll MAX = 1LL << 60;

ostream& operator<<(ostream& o, pii p){
    return o << '(' << p.F << ',' << p.S << ')';
}

vector<int> who_wins(vector<int> a, vector<int> r, vector<int> u, vector<int> v) {
    int n = a.size();

    vector<int> ans(n);
    int p = 0;
    for(int i = 0; i < n; i++){
        if(u[i] != v[i]) continue;
        while(p <= i){
            ans[p] = r[i];
            p++;
        }
    }

    return ans;
}
# Verdict Execution time Memory Grader output
1 Incorrect 4 ms 460 KB 3rd lines differ - on the 5th token, expected: '0', found: '1'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 204 KB 3rd lines differ - on the 2nd token, expected: '1', found: '0'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 6 ms 700 KB 3rd lines differ - on the 1st token, expected: '0', found: '1'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 5 ms 588 KB 3rd lines differ - on the 696th token, expected: '0', found: '1'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 6 ms 588 KB 3rd lines differ - on the 1st token, expected: '1', found: '0'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 4 ms 460 KB 3rd lines differ - on the 5th token, expected: '0', found: '1'
2 Halted 0 ms 0 KB -