#include <bits/stdc++.h>
using namespace std;
//#include <boost/multiprecision/cpp_int.hpp>
//using multiInt = boost::multiprecision::cpp_int;

using ll = long long int;
using ld = long double;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
template <typename Q_type>
using smaller_queue = priority_queue<Q_type, vector<Q_type>, greater<Q_type>>;

const int MOD_TYPE = 1;
const ll MOD = (MOD_TYPE == 1 ? (ll)(1e9 + 7) : 998244353);
const int INF = (int)1e9;
const ll LINF = (ll)4e18;
const double PI = acos(-1.0);

#define REP(i, m, n) for (ll i = m; i < (ll)(n); ++i)
#define rep(i, n) REP(i, 0, n)
#define MP make_pair
#define MT make_tuple
#define YES(n) cout << ((n) ? "YES" : "NO") << endl
#define Yes(n) cout << ((n) ? "Yes" : "No") << endl
#define Possible(n) cout << ((n) ? "Possible" : "Impossible") << endl
#define possible(n) cout << ((n) ? "possible" : "impossible") << endl
#define Yay(n) cout << ((n) ? "Yay!" : ":(") << endl
#define all(v) v.begin(), v.end()
#define NP(v) next_permutation(all(v))
#define dbg(x) cerr << #x << ":" << x << endl;

vector<int> Dx = {0, 0, -1, 1, -1, 1, -1, 1, 0};
vector<int> Dy = {1, -1, 0, 0, -1, -1, 1, 1, 0};

template <class T>
inline bool chmax(T &a, T b)
{
  if (a < b)
  {
    a = b;
    return 1;
  }
  return 0;
}
template <class T>
inline bool chmin(T &a, T b)
{
  if (a > b)
  {
    a = b;
    return 1;
  }
  return 0;
}

int main()
{
  cin.tie(0);
  ios::sync_with_stdio(false);
  cout << setprecision(50) << setiosflags(ios::fixed);

  ll n;
  cin >> n;
  ld x[100010], y[100010];
  char d[100010];
  rep(i, n) cin >> x[i] >> y[i] >> d[i];

  set<ld> event;
  event.insert(0.0);
  map<char, char> rev, rot;
  rev['R'] = 'L';
  rev['L'] = 'R';
  rev['U'] = 'U';
  rev['D'] = 'D';
  rot['R'] = 'U';
  rot['U'] = 'R';
  rot['D'] = 'L';
  rot['L'] = 'D';

  auto search = [&]() {
    ld x_max_l = -LINF;
    ld x_max_r = -LINF;
    ld x_max_ud = -LINF;
    rep(i, n)
    {
      if (d[i] == 'R')
        chmax(x_max_r, x[i]);
      else if (d[i] == 'L')
        chmax(x_max_l, x[i]);
      else
        chmax(x_max_ud, x[i]);
    }
    if (x_max_r != -LINF && x_max_l != -LINF && x_max_r < x_max_l)
      event.insert((x_max_l - x_max_r) / 2.0);
    if (x_max_r != -LINF && x_max_ud != -LINF && x_max_r < x_max_ud)
      event.insert(x_max_ud - x_max_r);
    if (x_max_l != -LINF && x_max_ud != -LINF && x_max_l > x_max_ud)
      event.insert(x_max_l - x_max_ud);
  };

  auto rev_f = [&]() {
    rep(i, n)
    {
      x[i] *= -1.0;
      d[i] = rev[d[i]];
    }
  };

  auto rot_f = [&]() {
    rep(i, n)
    {
      swap(x[i], y[i]);
      d[i] = rot[d[i]];
    }
  };
  search();
  rev_f();
  search();
  rot_f();
  search();
  rev_f();
  search();

  auto f = [&](ld t) {
    ld x_max = -LINF, x_min = LINF, y_max = -LINF, y_min = LINF;
    rep(i, n)
    {

      if (d[i] == 'R')
      {
        chmax(x_max, x[i] + t);
        chmin(x_min, x[i] + t);
      }
      else if (d[i] == 'L')
      {
        chmax(x_max, x[i] - t);
        chmin(x_min, x[i] - t);
      }
      else
      {
        chmax(x_max, x[i]);
        chmin(x_min, x[i]);
      }

      if (d[i] == 'U')
      {
        chmax(y_max, y[i] + t);
        chmin(y_min, y[i] + t);
      }
      else if (d[i] == 'D')
      {
        chmax(y_max, y[i] - t);
        chmin(y_min, y[i] - t);
      }
      else
      {
        chmax(y_max, y[i]);
        chmin(y_min, y[i]);
      }
    }
    return (x_max - x_min) * (y_max - y_min);
  };

  ld Min = LINF;
  for (auto t : event)
    chmin(Min, f(t));
  cout << Min << endl;
  return 0;
}


Measured memory_bytes: 3456