func_code_string: #include <bits/stdc++.h>   using namespace std;   long long a, b, c;   int getlength(int x, int y, int z) { return (x - y + 1) / (z); }   int main() {     int n, a, b, right, left;     cin >> n >> a >> b;     set<int> M;     int sh = (n + 1) / (b + 1);     n++;     b++;     M.insert(0);     M.insert(n);     int m, x;     cin >> m;     for (int i = 1; i <= m; i++) {       cin >> x;       auto ptr = M.upper_bound(x);       right = *ptr;       left = *--ptr;       sh -= (right - left) / b;       sh += (right - x) / b;       sh += (x - left) / b;       M.insert(x);       if (sh < a) {         cout << i << endl;         return 0;       }     }     cout << -1 << endl;   }   