#include <bits/stdc++.h>
using namespace std;
const int maxn = 100100;
int x[maxn], y[maxn]; char d[maxn];
int main(){
	int n; cin >> n;
	for(int i = 0; i < n; i++) cin >> x[i] >> y[i] >> d[i];
	auto apply = [&](double t, int ind){
		pair<double, double> ans;
		ans.first = x[ind];
		ans.second = y[ind];
		if(d[ind] == 'L') ans.first -= t;
		if(d[ind] == 'R') ans.first += t;
		if(d[ind] == 'U') ans.second += t;
		if(d[ind] == 'D') ans.second -= t;
		return ans;
	};
	auto fdx = [&](double t){
		double maxx, minx, maxy, miny;
		maxx = minx = apply(t, 0).first;
		maxy = miny = apply(t, 0).second;
		for(int i = 1; i < n; i++){
			auto r = apply(t, i);
			maxx = max(maxx, r.first);
			minx = min(minx, r.first);
			maxy = max(maxy, r.second);
			miny = min(miny, r.second);
		}
		return (maxx - minx) * (maxy - miny);
	};
	double lo = 0, hi = 1e9;
	for(int i = 0; i < 200; i++){
		double p0 = lo + (hi - lo) / 3;
		double p1 = hi - (hi - lo) / 3;
		if(fdx(p0) < fdx(p1)) hi = p1;
		else lo = p0;
	}
	cout << fixed << setprecision(12) << fdx(lo) << endl;
	return 0;
}
