#include <iostream>
#include <string>
#include <cstdlib>
#include <cmath>
#include <vector>
#include <map>
#include <set>
#include <algorithm>
#include <queue>
#include <stack>
#include <functional>
#include <bitset>
#include <assert.h>
using namespace std;
typedef long long ll;
typedef vector<ll> vl;
typedef vector<vl> vvl;
typedef vector<char> vc;
typedef vector<string> vs;
typedef vector<bool> vb;
typedef vector<double> vd;
typedef pair<ll,ll> P;
typedef vector<P> vpl;
typedef tuple<ll,ll,ll> tapu;
#define rep(i,n) for(ll i=0; i<(n); i++)
#define REP(i,a,b) for(int i=(a); i<(b); i++)
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
const int inf = 1<<30;
const ll linf = 1LL<<62;
const int MAX = 510000;
ll dy[8] = {0,1,0,-1,1,-1,1,-1};
ll dx[8] = {1,0,-1,0,1,-1,-1,1};
const double pi = acos(-1);
const double eps = 1e-7;
template<typename T1,typename T2> inline bool chmin(T1 &a,T2 b){
	if(a>b){
		a = b; return true;
	}
	else return false;
}
template<typename T1,typename T2> inline bool chmax(T1 &a,T2 b){
	if(a<b){
		a = b; return true;
	}
	else return false;
}
template<typename T1,typename T2> inline void print2(T1 a, T2 b){cout << a << " " << b << "\n";}
template<typename T1,typename T2,typename T3> inline void print3(T1 a, T2 b, T3 c){
	cout << a << " " << b << " " << c << "\n";
}
const int mod = 1e9 + 7;
//const int mod = 998244353;

ll n;
vd x(101010),y(101010);
vc d(101010);
map<char,int> mp;

double calc(double t){
	double xmin = inf, ymin = inf;
	double xmax = -inf, ymax = -inf;
	double X,Y;
	rep(i,n){
		X = x[i] + dx[mp[d[i]]] * t;
		Y = y[i] + dy[mp[d[i]]] * t;
		chmin(xmin,X);
		chmin(ymin,Y);
		chmax(xmax,X);
		chmax(ymax,Y);
	}
	return (ymax-ymin) * (xmax-xmin);
}

int main(){
	mp['R'] = 0, mp['U'] = 1, mp['L'] = 2, mp['D'] = 3;
	cin >> n;
	double umn = inf, umx = -inf, dmn = inf, dmx = -inf;
	double rmn = inf, rmx = -inf, lmn = inf, lmx = -inf;
	double xfmn = inf, xfmx = -inf, yfmn = inf, yfmx = -inf;
	rep(i,n){
		cin >> x[i] >> y[i] >> d[i];
		if(d[i]=='L'){
			chmax(lmx,x[i]);
			chmin(lmn,x[i]);
			chmax(yfmx,y[i]);
			chmin(yfmn,y[i]);
		}
		if(d[i]=='R'){
			chmax(rmx,x[i]);
			chmin(rmn,x[i]);
			chmax(yfmx,y[i]);
			chmin(yfmn,y[i]);
		}
		if(d[i]=='U'){
			chmax(umx,y[i]);
			chmin(umn,y[i]);
			chmax(xfmx,x[i]);
			chmin(xfmn,x[i]);
		}
		if(d[i]=='D'){
			chmax(dmx,y[i]);
			chmin(dmn,y[i]);
			chmax(xfmx,x[i]);
			chmin(xfmn,x[i]);
		}
	}
	vd pick;
	pick.push_back(0);
	if(xfmn!=inf && rmn!=inf) pick.push_back(max(xfmn-rmn,0.0));
	if(xfmn!=inf && rmx!=-inf) pick.push_back(max(xfmn-rmx,0.0));
	if(xfmx!=-inf && lmn!=inf) pick.push_back(max(lmn-xfmx,0.0));
	if(xfmx!=-inf && lmx!=-inf) pick.push_back(max(lmx-xfmx,0.0));
	if(xfmn!=inf && lmn!=inf) pick.push_back(max(lmn-xfmn,0.0));
	if(xfmn!=inf && lmx!=-inf) pick.push_back(max(lmx-xfmn,0.0));
	if(xfmx!=-inf && rmn!=inf) pick.push_back(max(xfmx-rmn,0.0));
	if(xfmx!=-inf && rmx!=-inf) pick.push_back(max(xfmx-rmx,0.0));
	if(rmx!=-inf && lmn!=inf) pick.push_back(max((lmn-rmx)/2.0,0.0));
	if(rmx!=-inf && lmx!=-inf) pick.push_back(max((lmx-rmx)/2.0,0.0));
	if(rmn!=inf && lmn!=inf) pick.push_back(max((lmn-rmn)/2.0,0.0));
	if(rmn!=inf && lmx!=-inf) pick.push_back(max((lmx-rmn)/2.0,0.0));

	if(yfmn!=inf && umn!=inf) pick.push_back(max(yfmn-umn,0.0));
	if(yfmn!=inf && umx!=-inf) pick.push_back(max(yfmn-umx,0.0));
	if(yfmx!=-inf && dmn!=inf) pick.push_back(max(dmn-yfmx,0.0));
	if(yfmx!=-inf && dmx!=-inf) pick.push_back(max(dmx-yfmx,0.0));
	if(yfmn!=inf && dmn!=inf) pick.push_back(max(dmn-yfmn,0.0));
	if(yfmn!=inf && dmx!=-inf) pick.push_back(max(dmx-yfmn,0.0));
	if(yfmx!=-inf && umn!=inf) pick.push_back(max(yfmx-umn,0.0));
	if(yfmx!=-inf && umx!=-inf) pick.push_back(max(yfmx-umx,0.0));
	if(umx!=-inf && dmn!=inf) pick.push_back(max((dmn-umx)/2.0,0.0));
	if(umx!=-inf && dmx!=-inf) pick.push_back(max((dmx-umx)/2.0,0.0));
	if(umn!=inf && dmn!=inf) pick.push_back(max((dmn-umn)/2.0,0.0));
	if(umn!=inf && dmx!=-inf) pick.push_back(max((dmx-umn)/2.0,0.0));
	double ans = linf;
	for(auto i : pick){
		chmin(ans,calc(i));
	}
	printf("%.12f\n",ans);
}

Measured memory_bytes: 1920