#include <bits/stdc++.h>
using namespace std;
multiset<int> s1, s2;
multiset<int, greater<int> > sj1, sj2;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int n, m, k;
  cin >> n >> m >> k;
  s1.insert(0);
  s2.insert(0);
  s1.insert(m);
  s2.insert(n);
  sj1.insert(m);
  sj2.insert(n);
  while (k--) {
    char ch;
    int x;
    cin >> ch >> x;
    multiset<int>::iterator it1, it2, it3;
    if (ch == 'H') {
      it1 = s1.lower_bound(x);
      it1--;
      it2 = s1.upper_bound(x);
      int x1 = *it1, x2 = *it2;
      it3 = sj1.find(x2 - x1);
      sj1.erase(it3);
      s1.insert(x);
      sj1.insert(x - x1);
      sj1.insert(x2 - x);
    } else {
      it1 = s2.lower_bound(x);
      it1--;
      it2 = s2.upper_bound(x);
      int x1 = *it1, x2 = *it2;
      it3 = sj2.find(x2 - x1);
      sj2.erase(it3);
      s2.insert(x);
      sj2.insert(x - x1);
      sj2.insert(x2 - x);
    }
    int m1 = (*sj1.begin()), m2 = (*sj2.begin());
    cout << (long long)m1 * m2 << endl;
  }
  return 0;
}
