Submission #981141

# Submission time Handle Problem Language Result Execution time Memory
981141 2024-05-12T21:50:07 Z aaaaaarroz Examination (JOI19_examination) C++17
100 / 100
1592 ms 2196 KB
#include <bits/stdc++.h>
using namespace std;
    
#pragma GCC target("avx2")
#pragma GCC optimize("O3")
//#pragma GCC optimize("unroll-loops")
int x[100001], y[100001];
    
int main() {
    int n, q;
    cin >> n >> q;
    for (int i = 0; i < n; i++) {
    cin >> x[i] >> y[i];
    }
    for (int i = 0; i < q; i++) {
    int ans = 0;
    int a, b, c;
    cin >> a >> b >> c;
    for (int j = 0; j < n; j++) {
        if (x[j] >= a && y[j] >= b && x[j] + y[j] >= c) ans++;
    }
    cout << ans << '\n';
    }
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 348 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 1 ms 344 KB Output is correct
7 Correct 9 ms 348 KB Output is correct
8 Correct 9 ms 348 KB Output is correct
9 Correct 9 ms 348 KB Output is correct
10 Correct 8 ms 348 KB Output is correct
11 Correct 8 ms 348 KB Output is correct
12 Correct 7 ms 348 KB Output is correct
13 Correct 9 ms 344 KB Output is correct
14 Correct 9 ms 344 KB Output is correct
15 Correct 10 ms 476 KB Output is correct
16 Correct 7 ms 348 KB Output is correct
17 Correct 8 ms 484 KB Output is correct
18 Correct 7 ms 348 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1533 ms 1872 KB Output is correct
2 Correct 1486 ms 1960 KB Output is correct
3 Correct 1483 ms 1592 KB Output is correct
4 Correct 1515 ms 1616 KB Output is correct
5 Correct 1468 ms 1968 KB Output is correct
6 Correct 1477 ms 1620 KB Output is correct
7 Correct 1506 ms 1656 KB Output is correct
8 Correct 1543 ms 1872 KB Output is correct
9 Correct 1520 ms 1772 KB Output is correct
10 Correct 1457 ms 1360 KB Output is correct
11 Correct 1592 ms 1512 KB Output is correct
12 Correct 1463 ms 1448 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1533 ms 1872 KB Output is correct
2 Correct 1486 ms 1960 KB Output is correct
3 Correct 1483 ms 1592 KB Output is correct
4 Correct 1515 ms 1616 KB Output is correct
5 Correct 1468 ms 1968 KB Output is correct
6 Correct 1477 ms 1620 KB Output is correct
7 Correct 1506 ms 1656 KB Output is correct
8 Correct 1543 ms 1872 KB Output is correct
9 Correct 1520 ms 1772 KB Output is correct
10 Correct 1457 ms 1360 KB Output is correct
11 Correct 1592 ms 1512 KB Output is correct
12 Correct 1463 ms 1448 KB Output is correct
13 Correct 1542 ms 1648 KB Output is correct
14 Correct 1507 ms 1620 KB Output is correct
15 Correct 1479 ms 1876 KB Output is correct
16 Correct 1485 ms 1724 KB Output is correct
17 Correct 1524 ms 1924 KB Output is correct
18 Correct 1447 ms 1744 KB Output is correct
19 Correct 1495 ms 2132 KB Output is correct
20 Correct 1506 ms 1944 KB Output is correct
21 Correct 1518 ms 1960 KB Output is correct
22 Correct 1477 ms 2096 KB Output is correct
23 Correct 1482 ms 1872 KB Output is correct
24 Correct 1532 ms 2008 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 0 ms 348 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 1 ms 344 KB Output is correct
7 Correct 9 ms 348 KB Output is correct
8 Correct 9 ms 348 KB Output is correct
9 Correct 9 ms 348 KB Output is correct
10 Correct 8 ms 348 KB Output is correct
11 Correct 8 ms 348 KB Output is correct
12 Correct 7 ms 348 KB Output is correct
13 Correct 9 ms 344 KB Output is correct
14 Correct 9 ms 344 KB Output is correct
15 Correct 10 ms 476 KB Output is correct
16 Correct 7 ms 348 KB Output is correct
17 Correct 8 ms 484 KB Output is correct
18 Correct 7 ms 348 KB Output is correct
19 Correct 1533 ms 1872 KB Output is correct
20 Correct 1486 ms 1960 KB Output is correct
21 Correct 1483 ms 1592 KB Output is correct
22 Correct 1515 ms 1616 KB Output is correct
23 Correct 1468 ms 1968 KB Output is correct
24 Correct 1477 ms 1620 KB Output is correct
25 Correct 1506 ms 1656 KB Output is correct
26 Correct 1543 ms 1872 KB Output is correct
27 Correct 1520 ms 1772 KB Output is correct
28 Correct 1457 ms 1360 KB Output is correct
29 Correct 1592 ms 1512 KB Output is correct
30 Correct 1463 ms 1448 KB Output is correct
31 Correct 1542 ms 1648 KB Output is correct
32 Correct 1507 ms 1620 KB Output is correct
33 Correct 1479 ms 1876 KB Output is correct
34 Correct 1485 ms 1724 KB Output is correct
35 Correct 1524 ms 1924 KB Output is correct
36 Correct 1447 ms 1744 KB Output is correct
37 Correct 1495 ms 2132 KB Output is correct
38 Correct 1506 ms 1944 KB Output is correct
39 Correct 1518 ms 1960 KB Output is correct
40 Correct 1477 ms 2096 KB Output is correct
41 Correct 1482 ms 1872 KB Output is correct
42 Correct 1532 ms 2008 KB Output is correct
43 Correct 1555 ms 2068 KB Output is correct
44 Correct 1578 ms 1660 KB Output is correct
45 Correct 1549 ms 1768 KB Output is correct
46 Correct 1539 ms 2196 KB Output is correct
47 Correct 1491 ms 2060 KB Output is correct
48 Correct 1502 ms 1768 KB Output is correct
49 Correct 1531 ms 1920 KB Output is correct
50 Correct 1563 ms 1884 KB Output is correct
51 Correct 1531 ms 2128 KB Output is correct
52 Correct 1489 ms 1360 KB Output is correct
53 Correct 1528 ms 1872 KB Output is correct