#include <bits/stdc++.h>
using namespace std;

#define INF 1e18

int N;
vector<long long> x;
vector<long long> y;
vector<char> d;

double f( double t )
{
	double xmax = -INF;
	double xmin = INF;
	double ymax = -INF;
	double ymin = INF;
	for( int i = 0; i < N; i++) {
		double xx = x[i];
		double yy = y[i];
		char dd = d[i];
		if( dd == 'R' ) {
			xx += t;
		}
		else if( dd == 'L' ) {
			xx -= t;
		}
		else if( dd == 'U' ) {
			yy += t;
		}
		else if( dd == 'D' ) {
			yy -= t;
		}
		xmax = max( xmax, xx );
		xmin = min( xmin, xx );
		ymax = max( ymax, yy );
		ymin = min( ymin, yy );
	}
	return ( xmax - xmin ) * ( ymax - ymin );
}

int main() {

	cin >> N;
	x = vector<long long>( N );
	y = vector<long long>( N );
	d = vector<char>( N );
	for( int i = 0; i < N; i++ ) {
		cin >> x[i] >> y[i] >> d[i];
	}

	double l = 0;
	double r = 1e9;
	double ans = INF;
	for( int i = 0; i < 200; i++ ) {
		double t1 = ( l * 2 + r ) / 3;
		double t2 = ( l + r * 2 ) / 3;
		double res1 = f( t1 );
		double res2 = f( t2 );
		if( res1 > res2 ) {
			l = t1;
		}
		else {
			r = t2;
		}
		ans = min( ans, min( res1, res2 ) );
	}

	cout << fixed << setprecision(12) << ans << endl;

	return 0;
}