n, q = list(map(int, input().split()))
arr = []
for _ in range(n):
score = list(map(int, input().split()))
arr.append(score)
for i in range(q):
count = 0
x, y, z = list(map(int, input().split()))
for k in range(n):
if arr[k][0] >= x and arr[k][1] >= y and arr[k][0] + arr[k][1] >= z:
count += 1
print(count)
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
22 ms |
3300 KB |
Output is correct |
2 |
Correct |
23 ms |
3384 KB |
Output is correct |
3 |
Correct |
21 ms |
3300 KB |
Output is correct |
4 |
Correct |
23 ms |
3308 KB |
Output is correct |
5 |
Correct |
21 ms |
3300 KB |
Output is correct |
6 |
Correct |
22 ms |
3308 KB |
Output is correct |
7 |
Execution timed out |
3084 ms |
4152 KB |
Time limit exceeded |
8 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
3070 ms |
20960 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
3070 ms |
20960 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
22 ms |
3300 KB |
Output is correct |
2 |
Correct |
23 ms |
3384 KB |
Output is correct |
3 |
Correct |
21 ms |
3300 KB |
Output is correct |
4 |
Correct |
23 ms |
3308 KB |
Output is correct |
5 |
Correct |
21 ms |
3300 KB |
Output is correct |
6 |
Correct |
22 ms |
3308 KB |
Output is correct |
7 |
Execution timed out |
3084 ms |
4152 KB |
Time limit exceeded |
8 |
Halted |
0 ms |
0 KB |
- |