#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
using V = vector<int>;
using Vll = vector<ll>;
using Vld = vector<ld>;
using Vbo = vector<bool>;
using VV = vector<V>;
using VVll = vector<Vll>;
using VVld = vector<Vld>;
using VVbo = vector<Vbo>;
using P = pair<int, int>;
using Pll = pair<ll, ll>;
using Pld = pair<ld, ld>;
#define rep2(i, m, n) for(ll i=int(m); i<int(n); ++i)
#define drep2(i, m, n) for(ll i=int(m)-1; i>=int(n); --i)
#define rep(i, n) rep2(i, 0, n)
#define drep(i, n) drep2(i, n, 0)
#define all(a) a.begin(), a.end()
struct fast_ios { fast_ios(){ cin.tie(0); ios::sync_with_stdio(false); cout << fixed << setprecision(20); }; } fast_ios_;
template<typename T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return true; } return false; }
template<typename T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return true; } return false; }
template<typename T1, typename T2> istream &operator>>(istream &is, pair<T1, T2> &p) { is >> p.first >> p.second; return is; }
template<typename T1, typename T2> ostream &operator<<(ostream &os, const pair<T1, T2> &p) { os << "(" << p.first << ", " << p.second << ")"; return os; }
template<typename T> istream &operator>>(istream &is, vector<T> &v) { for (auto &e : v) is >> e; return is; }
template<typename T> ostream &operator<<(ostream &os, const vector<T> &v) { for (auto &e : v) os << e << " "; return os; }
template<typename T> inline int count_between(vector<T> &a, T l, T r) { return lower_bound(all(a), r) - lower_bound(all(a), l); } // [l, r)
inline int Log2(ll x) { int k; for (k = 0; x > 0; ++k) x >>= 1; return k; } // number of binary digits
const int INF  = 1<<30;
const ll INFll = 1ll<<62;
const ld EPS   = 1e-10;
const int MOD  = int(1e9)+7;


string rf = "RLUD";

int main() {
  ll n; cin >> n;
  VVld xy_max(2, Vld(4, -INF)); 
  VVld xy_min(2, Vld(4, INF)); 

  rep(i, n) {
    Vld x(2);
    char d;
    cin >> x[0] >> x[1] >> d;
    rep(j, 4) if (d == rf[j]) {
      chmax(xy_max[0][j], x[0]);
      chmax(xy_max[1][j], x[1]);
      chmin(xy_min[0][j], x[0]);
      chmin(xy_min[1][j], x[1]);
    }
  }

  Vld t(13);
  t[0] = max(xy_max[0][2], xy_max[0][3]) - xy_max[0][0];
  t[1] = xy_max[0][1] - max(xy_max[0][2], xy_max[0][3]);
  t[2] = (xy_max[0][1] - xy_max[0][0]) / 2;
  t[3] = max(xy_max[1][0], xy_max[1][1]) - xy_max[1][2];
  t[4] = xy_max[1][3] - max(xy_max[1][0], xy_max[1][1]);
  t[5] = (xy_max[1][3] - xy_max[1][2]) / 2;
  t[6] = min(xy_min[0][2], xy_min[0][3]) - xy_min[0][0];
  t[7] = xy_min[0][1] - min(xy_min[0][2], xy_min[0][3]);
  t[8] = (xy_min[0][1] - xy_min[0][0]) / 2;
  t[9] = min(xy_min[1][0], xy_min[1][1]) - xy_min[1][2];
  t[10] = xy_min[1][3] - min(xy_min[1][0], xy_min[1][1]);
  t[11] = (xy_min[1][3] - xy_min[1][2]) / 2;

  ld ans = INFll;
  rep(i, 13) {
    if (t[i] < 0) continue;
    ld x_max = -INFll;
    chmax(x_max, xy_max[0][0] + t[i]);
    chmax(x_max, xy_max[0][1] - t[i]);
    chmax(x_max, xy_max[0][2]);
    chmax(x_max, xy_max[0][3]);
    ld y_max = -INFll;
    chmax(y_max, xy_max[1][2] + t[i]);
    chmax(y_max, xy_max[1][3] - t[i]);
    chmax(y_max, xy_max[1][0]);
    chmax(y_max, xy_max[1][1]);
    ld x_min = INFll;
    chmin(x_min, xy_min[0][0] + t[i]);
    chmin(x_min, xy_min[0][1] - t[i]);
    chmin(x_min, xy_min[0][2]);
    chmin(x_min, xy_min[0][3]);
    ld y_min = INFll;
    chmin(y_min, xy_min[1][2] + t[i]);
    chmin(y_min, xy_min[1][3] - t[i]);
    chmin(y_min, xy_min[1][0]);
    chmin(y_min, xy_min[1][1]);

    chmin(ans, (x_max - x_min) * (y_max - y_min));
  }
  
  cout << ans << "\n";
  return 0;
}


Measured memory_bytes: 256