#include <bits/stdc++.h>
using namespace std;
const int N = 3e5 + 5;
int n, m, t, W, L, x, pp;
int cntW[N], cntL[N];
set<int> W1, L1;
set<int, greater<int> > WW, LL;
set<int>::iterator it;
char a[5];
int main() {
  scanf("%d%d%d", &W, &L, &n);
  cntL[L]++, cntW[W]++;
  W1.insert(W), W1.insert(0), L1.insert(L), L1.insert(0);
  WW.insert(W), LL.insert(L);
  for (int i = 1; i <= n; i++) {
    scanf("%s%d", a, &x);
    if (a[0] == 'H') {
      it = L1.lower_bound(x);
      int r = *it;
      it--;
      int l = *it, len1 = r - x, len2 = x - l;
      if (--cntL[r - l] == 0) LL.erase(r - l);
      if (++cntL[len1] == 1) LL.insert(len1);
      if (++cntL[len2] == 1) LL.insert(len2);
      L1.insert(x);
    } else {
      it = W1.lower_bound(x);
      int r = *it;
      it--;
      int l = *it, len1 = r - x, len2 = x - l;
      if (--cntW[r - l] == 0) WW.erase(r - l);
      if (++cntW[len1] == 1) WW.insert(len1);
      if (++cntW[len2] == 1) WW.insert(len2);
      W1.insert(x);
    }
    cout << 1ll * (*WW.begin()) * (*LL.begin()) << endl;
  }
  return 0;
}
