#include <bits/stdc++.h>
using namespace std;
inline int getInt() {
  int s;
  scanf("%d", &s);
  return s;
}
inline char getChar() {
  char b[2];
  scanf("%s", b);
  return b[0];
}
int main() {
  const int w = getInt();
  const int h = getInt();
  const int n = getInt();
  set<int> xs;
  xs.insert(0);
  xs.insert(w);
  set<int> ys;
  ys.insert(0);
  ys.insert(h);
  set<pair<int, int> > xv;
  set<pair<int, int> > yv;
  priority_queue<pair<int, pair<int, int> > > xq;
  xq.push(pair<int, pair<int, int> >(w, make_pair(0, w)));
  priority_queue<pair<int, pair<int, int> > > yq;
  yq.push(pair<int, pair<int, int> >(h, make_pair(0, h)));
  auto cut = [](int pos, set<int> &s, set<pair<int, int> > &v,
                priority_queue<pair<int, pair<int, int> > > &q) {
    auto it = s.insert(pos).first;
    const int a = *(--it);
    ++it;
    const int b = *(++it);
    v.insert(make_pair(a, b));
    q.push(pair<int, pair<int, int> >(pos - a, make_pair(a, pos)));
    q.push(pair<int, pair<int, int> >(b - pos, make_pair(pos, b)));
  };
  auto query = [](set<int> &s, set<pair<int, int> > &v,
                  priority_queue<pair<int, pair<int, int> > > &q) {
    while (q.size()) {
      pair<int, pair<int, int> > d = q.top();
      if (v.count(d.second)) {
        v.erase(d.second);
        q.pop();
        continue;
      }
      return d.first;
    }
    return 0;
  };
  for (int i = 0; i < (int)(n); i++) {
    const char c = getChar();
    const int pos = getInt();
    if (c == 'H')
      cut(pos, ys, yv, yq);
    else
      cut(pos, xs, xv, xq);
    printf("%lld\n",
           (long long)query(xs, xv, xq) * (long long)query(ys, yv, yq));
  }
  return 0;
}
