#include #include #include #include #define repeat(i,n) for (int i = 0; (i) < (n); ++(i)) using namespace std; #define N 5000 #define L (2*N-1) int main() { // input int n; scanf("%d", &n); map > a; repeat (i,n) { int it; scanf("%d", &it); a[it].push_back(i); } bitset b; repeat (i,n) { int it; scanf("%d", &it); b[i] = it; } // compute bitset c; for (auto it : a) { bitset d; for (int i : it.second) { d |= b << i; } c ^= d; } // output repeat (i,2*n-1) { printf("%s\n", c[i] ? "ODD" : "EVEN"); } return 0; }