func_code_string: #include <bits/stdc++.h>   using namespace std;   const int oo = (int)1e9;   const double PI = 2 * acos(0.0);   const double eps = 1e-9;   int n, m;   vector<int> len;   vector<pair<int, int> > pos;   deque<int> ans;   vector<bool> vis;   int find(int x) {     for (int i = 0; i < (int)len.size(); ++i) {       if (len[i] == x and !vis[i]) return i;     }     return -1;   }   int main() {     cin >> n >> m;     pos = vector<pair<int, int> >(n);     len = vector<int>(m);     for (int i = 0; i < n; ++i) cin >> pos[i].first >> pos[i].second;     for (int i = 0; i < m; ++i) cin >> len[i];     if (n % 2) {       cout <<  NO n ;       return 0;     }     bool good = 0;     vis = vector<bool>(m, 0);     ans = deque<int>();     for (int i = 0; i < n; i += 2) {       int prev = (i + n - 1) % n;       int dist1 = (int)hypot(pos[prev].first - pos[i].first,                              pos[prev].second - pos[i].second);       int dist2 = (int)hypot(pos[i + 1].first - pos[i].first,                              pos[i + 1].second - pos[i].second);       int idx = find(dist1 + dist2);       if (idx != -1) {         vis[idx] = 1;         ans.push_back(idx);       } else         goto no;     }     cout <<  YES  << endl;     for (int i = 0; i < n; ++i) {       if (i % 2 == 1)         cout << -1 <<    ;       else {         cout << ans.front() + 1 <<    ;         ans.pop_front();       }     }     cout << endl;     return 0;   no:;     vis = vector<bool>(m, 0);     ans = deque<int>();     for (int i = 1; i < n; i += 2) {       int nxt = (i + n + 1) % n;       int dist1 = (int)hypot(pos[i - 1].first - pos[i].first,                              pos[i - 1].second - pos[i].second);       int dist2 = (int)hypot(pos[nxt].first - pos[i].first,                              pos[nxt].second - pos[i].second);       int idx = find(dist1 + dist2);       if (idx != -1) {         vis[idx] = 1;         ans.push_back(idx);       } else {         good = 0;         goto noo;       }     }     cout <<  YES  << endl;     for (int i = 0; i < n; ++i) {       if (i % 2 == 0)         cout << -1 <<    ;       else {         cout << ans.front() + 1 <<    ;         ans.pop_front();       }     }     cout << endl;     return 0;   noo:;     cout <<  NO  << endl;     return 0;   }   