Submission #237078

# Submission time Handle Problem Language Result Execution time Memory
237078 2020-06-04T13:08:22 Z MrRobot_28 Plahte (COCI17_plahte) C++17
0 / 160
2000 ms 8952 KB
#include<bits/stdc++.h>
using namespace std;

signed main() {
	ios_base::sync_with_stdio(false);
	cin.tie(NULL);
	cout.tie(NULL);
	int n, m;
	cin >> n >> m;
	vector <pair <pair <int, int>, pair <int, int> > > pol(n);
	for(int i = 0; i < n; i++)
	{
		cin >> pol[i].first.first >> pol[i].first.second >> pol[i].second.first >> pol[i].second.second;
	}
	vector <pair <int, int> > x(m);
	vector <int> type(m);
	for(int i = 0; i < m; i++)
	{
		cin >> x[i].first >> x[i].second >> type[i];
	}
	for(int i = 0; i < n; i++)
	{
		set <int> t;
		for(int j = 0; j < m; j++)
		{
			if(x[j].first >= pol[i].first.first && x[j].first <= pol[i].second.first && x[j].second >= pol[i].first.second && x[j].second <= pol[i].second.second)
			{
				t.insert(type[j]);
			}
		}
		cout << t.size() << "\n";
	}
    return 0;
}
# Verdict Execution time Memory Grader output
1 Execution timed out 2067 ms 3596 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2066 ms 3704 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2071 ms 5880 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2088 ms 8952 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2065 ms 8952 KB Time limit exceeded
2 Halted 0 ms 0 KB -