func_code_string: #include <bits/stdc++.h>   using namespace std;   int main() {     cin.tie(0);     cout.tie(0);     iostream::sync_with_stdio(false);     long long n, m;     cin >> n >> m;     set<int> taken_lines, taken_cols;     long long base = n * n;     for (int i = 0; i < m; ++i) {       int x, y;       cin >> x >> y;       bool lined = false, coled = false;       if (taken_lines.count(x) == 0) lined = true;       if (taken_cols.count(y) == 0) coled = true;       if (lined) {         base -= n - taken_cols.size();       }       if (coled) {         base -= n - taken_lines.size();       }       if (lined && coled) {         base++;       }       taken_lines.insert(x);       taken_cols.insert(y);       cout << base <<    ;     }     cout <<   n ;   }   