#include <bits/stdc++.h>
using namespace std;
const int MAXN = 200005;
int mx[MAXN << 2][2];
int L[MAXN << 2][2];
int R[MAXN << 2][2];
int ll[MAXN << 2][2];
int rr[MAXN << 2][2];
int h, w;
void pushup(int o, int f) { mx[o][f] = max(mx[o << 1][f], mx[o << 1 | 1][f]); }
void build(int l, int r, int o, int f, int v) {
  mx[o][f] = v;
  if (l == r) {
    L[o][f] = 0;
    R[o][f] = v;
    return;
  }
  int m = l + r >> 1;
  build(l, m, o << 1, f, v);
  build(m + 1, r, o << 1 | 1, f, v);
}
int tl[2];
int tr[2];
void pushdown(int o, int f) {
  if (ll[o][f] != 0 || rr[o][f] != 0) {
    ll[o << 1][f] = ll[o << 1 | 1][f] = ll[o][f];
    rr[o << 1][f] = rr[o << 1 | 1][f] = rr[o][f];
    L[o << 1][f] = L[o << 1 | 1][f] = ll[o][f];
    R[o << 1][f] = R[o << 1 | 1][f] = rr[o][f];
    mx[o << 1 | 1][f] = mx[o << 1][f] = rr[o][f] - ll[o][f];
    ll[o][f] = rr[o][f] = 0;
  }
}
void query(int l, int r, int o, int p, int f) {
  if (l == r) {
    tl[f] = L[o][f];
    tr[f] = R[o][f];
    return;
  }
  pushdown(o, f);
  int m = l + r >> 1;
  if (p <= m)
    query(l, m, o << 1, p, f);
  else
    query(m + 1, r, o << 1 | 1, p, f);
  pushup(o, f);
}
void update(int l, int r, int o, int L1, int R1, int f) {
  if (L1 <= l && r <= R1) {
    L[o][f] = ll[o][f] = L1;
    R[o][f] = rr[o][f] = R1;
    mx[o][f] = R1 - L1;
    return;
  }
  pushdown(o, f);
  int m = l + r >> 1;
  if (L1 <= m) update(l, m, o << 1, L1, R1, f);
  if (m < R1) update(m + 1, r, o << 1 | 1, L1, R1, f);
  pushup(o, f);
}
int main() {
  int w, h, n;
  scanf("%d%d%d", &w, &h, &n);
  int mx1 = max(w, h);
  build(1, h, 1, 0, h);
  build(1, w, 1, 1, w);
  while (n--) {
    char s[3];
    int v;
    scanf("%s%d", s, &v);
    if (s[0] == 'H') {
      query(1, h, 1, v, 0);
      update(1, h, 1, tl[0], v, 0);
      update(1, h, 1, v, tr[0], 0);
    } else {
      query(1, w, 1, v, 1);
      update(1, w, 1, tl[1], v, 1);
      update(1, w, 1, v, tr[1], 1);
    }
    cout << (long long)mx[1][0] * mx[1][1] << endl;
  }
  return 0;
}
