Submission #1108593

# Submission time Handle Problem Language Result Execution time Memory
1108593 2024-11-04T14:22:57 Z FubuGold Examination (JOI19_examination) C++14
0 / 100
2 ms 592 KB
#include <bits/stdc++.h>

using namespace std;

const int MAXN = 1000;
int s[MAXN+1],t[MAXN+1];
int n,q;

int main() {
    cin.tie(0) -> sync_with_stdio(0);
    cin >> n >> q;
    for (int i=1;i<=n;i++) cin >> s[i] >> t[i];
    for (int i=1;i<=q;i++) {
        int a,b,c; cin >> a >> b >> c;
        int ans = 0;
        for (int j=1;j<=n;j++) {
            if (s[j] >= a && t[j] >= b && s[j] + t[j] >= c) ans++;
        }
        cout << ans << '\n';
    }
    return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 1 ms 336 KB Output is correct
2 Correct 1 ms 508 KB Output is correct
3 Correct 1 ms 336 KB Output is correct
4 Correct 1 ms 336 KB Output is correct
5 Correct 1 ms 336 KB Output is correct
6 Correct 1 ms 336 KB Output is correct
7 Runtime error 2 ms 592 KB Execution killed with signal 11
8 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Runtime error 1 ms 592 KB Execution killed with signal 11
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Runtime error 1 ms 592 KB Execution killed with signal 11
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 1 ms 336 KB Output is correct
2 Correct 1 ms 508 KB Output is correct
3 Correct 1 ms 336 KB Output is correct
4 Correct 1 ms 336 KB Output is correct
5 Correct 1 ms 336 KB Output is correct
6 Correct 1 ms 336 KB Output is correct
7 Runtime error 2 ms 592 KB Execution killed with signal 11
8 Halted 0 ms 0 KB -