func_code_string: #include <bits/stdc++.h>   using namespace std;   vector<long long> factors(long long n) {     vector<long long> first;     long long tem = 1;     for (long long x = 2; x * x <= n; x++) {       while (n % x == 0) {         first.push_back(x);         n /= x;       }     }     if (n > 1) first.push_back(n);     return first;   }   long long stringToint(string str) {     int num = stoi(str);     return num;   }   int hamming(int a, int b) { return __builtin_popcount(a ^ b); }   bool cmp(int a, int b) { return a > b; }   void reset() {     for (int i = 0; i < 200000 + 100; i++) {     }   }   int main() {     ios::sync_with_stdio(false);     cin.tie(nullptr);     int n, d;     while (cin >> n >> d) {       int m;       cin >> m;       for (int i = 0, x, y; i < m; i++) {         cin >> x >> y;         if (abs(x - y) >= 0 && abs(x - y) <= d && x + y <= n + n - d &&             x + y >= d && (x + y != 0 || x - y != 0))           cout <<  YES n ;         else           cout <<  NO n ;       }     }     return 0;   }   