Submission #929051

# Submission time Handle Problem Language Result Execution time Memory
929051 2024-02-17T14:54:53 Z NourWael Plahte (COCI17_plahte) C++17
0 / 160
2000 ms 524288 KB
#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 time Memory Grader output
1 Execution timed out 2037 ms 200024 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2047 ms 280220 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2059 ms 436696 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Runtime error 162 ms 524288 KB Execution killed with signal 9
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Runtime error 174 ms 524288 KB Execution killed with signal 9
2 Halted 0 ms 0 KB -