// NOTE: it is recommended to use this even if you don't understand the following code. #include #include #include #include #define MAXM 100000 #define MAXL 100000 #define MAXS 128 int K, L, M, N, i; int A[MAXM], B[MAXM], leaves[MAXM]; long long T1[MAXM], T2[MAXM]; int U[MAXL], V[MAXL]; char ans[MAXS]; int main() { // uncomment the two following lines if you want to read/write from files // freopen("input.txt", "r", stdin); // freopen("output.txt", "w", stdout); assert(3 == scanf("%d%d%d", &N, &M, &K)); for (i = 0; i < M; ++i) assert(4 == scanf("%d%lld%d%lld", &A[i], &T1[i], &B[i], &T2[i])); assert(1 == scanf("%d", &L)); for (i = 0; i < L; ++i) assert(2 == scanf("%d%d", &U[i], &V[i])); ans[0] = 0; // INSERT YOUR CODE HERE printf("%s\n", ans); // only if answer is YES for (i = 0; i < M; ++i) printf("%d ", leaves[i]); printf("\n"); return 0; }