# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
434486 | 2021-06-21T11:06:37 Z | medmdg | Toy Train (IOI17_train) | C++14 | 0 ms | 0 KB |
#include<bits/stdc++.h> #include "train.h" #define ll int vector<int> who_wins(vector<int> a, vector<int> r, vector<int> u, vector<int> v) { vector<ll> win; for(int i=0;i<u.size();i++){ if(u[i]==v[i]){ if(r[i]){ if(a[i]) while(win.size()<i) win.push_back(1); }else{ if(!a[i]) win.push_back(0); } } } return win; }