Pagini recente » Cod sursa (job #2836437) | Cod sursa (job #2559902) | Cod sursa (job #2461158) | Cod sursa (job #974599) | Cod sursa (job #2925497)
#include <bits/stdc++.h>
using namespace std;
ifstream in("zc.in");
ofstream out("zc.out");
int n,m;
vector<pair<int,int>>vl,vc;
int main()
{
in >> n >> m;
for (int i = 1; i <= n; i++)
{
int x,y;
in >> x >> y;
vl.push_back({x,x});
vl.push_back({x + 1,y});
vl.push_back({x + 2,y});
vl.push_back({x - 1,y});
vl.push_back({x - 2,y});
vl.push_back({x + 1,y + 1});
vl.push_back({x + 1,y - 1});
vl.push_back({x - 1,y + 1});
vl.push_back({x - 1,y - 1});
vl.push_back({x,y + 1});
vl.push_back({x,y + 2});
vl.push_back({x,y - 1});
vl.push_back({x,y - 2});
vl.push_back({y,x});
vl.push_back({y + 1,x});
vl.push_back({y + 2,x});
vl.push_back({y - 1,x});
vl.push_back({y - 2,x});
vl.push_back({y + 1,x + 1});
vl.push_back({y + 1,x - 1});
vl.push_back({y - 1,x + 1});
vl.push_back({y - 1,x - 1});
vl.push_back({y,x + 1});
vl.push_back({y,x + 2});
vl.push_back({y,x - 1});
vl.push_back({y,x - 2});
}
sort(vl.begin(),vl.end());
sort(vc.begin(),vc.end());
//int lin = 0,col = 0;
//for (int i = 1; i <= m; i++)
//{
// char D;
// int x;
// if (D == 'N' or D == 'S')
// {
// int st,
// }
//}
return 0;
}