Submission #964221

#TimeUsernameProblemLanguageResultExecution timeMemory
964221UnforgettableplExamination (JOI19_examination)C++17
2 / 100
3055 ms3688 KiB
#include <bits/stdc++.h> using namespace std; #define int long long int32_t main(){ ios_base::sync_with_stdio(false); cin.tie(nullptr); int n,q; cin >> n >> q; vector<pair<int,int>> students(n); for(auto&i:students)cin>>i.first>>i.second; for(int i=1;i<=q;i++){ int a,b,c;cin>>a>>b>>c; int ans = 0; for(auto&i:students)if(i.first>=a and i.second>=b and i.first+i.second>=c)ans++; cout << ans << '\n'; } }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...