Submission #929051

#TimeUsernameProblemLanguageResultExecution timeMemory
929051NourWaelPlahte (COCI17_plahte)C++17
0 / 160
2059 ms524288 KiB
#include <bits/stdc++.h> #define int long long using namespace std; int n,m; pair<pair<int,int>,pair<int,int>> v[80001]; bitset<80001> col[80001]; signed main() { ios_base::sync_with_stdio(0); cin.tie(NULL); cout.tie(NULL); cin>>n>>m; for(int i=0; i<n; i++) { int a,b,c,d; cin>>a>>b>>c>>d; v[i] = {{a,b},{c,d}}; } for(int i=0; i<m; i++) { int x,y,c; cin>>x>>y>>c; for(int j=0; j<n; j++) { if(v[j].first.first<=x && x<=v[j].second.first && v[j].first.second<=y && y<=v[j].second.second) col[j][c] = 1; } } for(int i=0; i<n; i++) cout<<col[i].count()<<'\n'; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...