#include <bits/stdc++.h>
using namespace std;
long long quickpow(long long a, long long b, long long MOD) {
  long long ans = 1;
  a %= MOD;
  while (b) {
    if (b & 1ll) ans = ans * a % MOD;
    a = a * a % MOD, b >>= 1;
  }
  return ans;
}
long long gcd(long long a, long long b) {
  return a % b == 0 ? b : gcd(b, a % b);
}
char str[5];
int main() {
  int w, h, n, num;
  while (~scanf("%d%d%d", &w, &h, &n)) {
    set<int> hor, vec;
    multiset<int> hordiff, vecdiff;
    set<int>::iterator pre, nxt;
    multiset<int>::iterator it;
    hor.insert(0), hor.insert(w);
    vec.insert(0), vec.insert(h);
    hordiff.insert(w);
    vecdiff.insert(h);
    for (int i = 0; i < n; i++) {
      scanf("%s%d", str, &num);
      if (str[0] == 'H') {
        pre = vec.upper_bound(num);
        nxt = pre;
        pre--;
        int actdiff = *nxt - *pre;
        vec.insert(num);
        it = vecdiff.find(actdiff);
        vecdiff.erase(it);
        vecdiff.insert(num - *pre), vecdiff.insert(*nxt - num);
      } else {
        pre = hor.upper_bound(num);
        nxt = pre;
        pre--;
        int actdiff = *nxt - *pre;
        hor.insert(num);
        it = hordiff.find(actdiff);
        hordiff.erase(it);
        hordiff.insert(num - *pre), hordiff.insert(*nxt - num);
      }
      multiset<int>::iterator it1 = hordiff.end(), it2 = vecdiff.end();
      it1--, it2--;
      printf("%I64d\n", (long long)(*it1) * (long long)(*it2));
    }
  }
  return 0;
}
