#line 1 "main.cpp"
#include <iostream>
#include <algorithm>
#include <vector>
#include <map>

using namespace std;
using lint = long long;

void solve() {
    lint h, w;
    int q;
    cin >> h >> w >> q;

    lint ans = h * w;
    map<lint, lint> pos;

    while (q--) {
        lint x, y;
        cin >> x >> y;

        if (!pos.count(y)) pos[y] = h + 1;
        if (pos[y] >= x) {
            ans -= pos[y] - x;
            pos[y] = x;
        }

        cout << ans << "\n";
    }
}

int main() {
    cin.tie(nullptr);
    ios::sync_with_stdio(false);

    solve();

    return 0;
}