Submission #472893

#TimeUsernameProblemLanguageResultExecution timeMemory
472893AbdoMoPlahte (COCI17_plahte)C++17
0 / 160
2112 ms409072 KiB
#include<bits/stdc++.h> //#define int long long #define ll long long #define pb push_back const int mod = 1e9+7; using namespace std; bool comp(string a,string b) { if(a.size()==b.size()) { return a<b; } return a.size()<b.size(); } void solve(){ int n,m; cin>>n>>m; set<int>st[n]; int arr[n][4]; for(int i=0;i<n;i++) { for(int j=0;j<4;j++) { cin>>arr[i][j]; } } for(int i=0;i<m;i++) { int x,y,z; cin>>x>>y>>z; for(int j=0;j<n;j++) { //cout<<arr[j][0]<<" "<<arr[j][2]<<" "<<arr[j][1]<<" "<<arr[j][3]<<endl; if(x>=arr[j][0] && x<=arr[j][2] && y>=arr[j][1] && y<=arr[j][3]) { //cout<<pp[i][2]<<endl; st[j].insert(z); } } } for(int i=0;i<n;i++) { cout<<st[i].size()<<endl; } } int32_t main(){ int t=1; ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0); //cin>>t; while(t--){solve();} 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...