// NOTE: it is recommended to use this even if you don't understand the following code. #include #include #include #include // constraints #define MAXN 100005 #define MAXQ 100005 // input data int T, N, Q; int P[MAXN]; int L[MAXQ]; bool hacker; int main() { // uncomment the following lines if you want to read/write from files // freopen("input.txt", "r", stdin); // freopen("output.txt", "w", stdout); assert(1 == scanf("%d", &T)); for (int t = 0; t < T; ++t) { assert(2 == scanf("%d%d", &N, &Q)); for (int i = 1; i <= N; ++i) { assert(1 == scanf("%d", &P[i])); } for (int i = 1; i <= Q; ++i) { assert(1 == scanf("%d", &L[i])); } // insert your code here hacker = false; // print the result if (hacker) { puts("HACKER"); } else { puts("OK"); } } }