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

using i64 = int64_t;

constexpr double EPS = 1e-10;

double f(double tm, const vector<pair<i64, i64>> &v, const vector<int> &dir){
    double xmin = 1e10, xmax = -1e10, ymin = 1e10, ymax = -1e10;
    for(int i=0;i<v.size();++i){
        double x = v[i].first, y = v[i].second;
        if(dir[i] == 0)y += tm;
        else if(dir[i] == 1)x += tm;
        else if(dir[i] == 2)y -= tm;
        else x -= tm;
        xmin = min(xmin, x);
        xmax = max(xmax, x);
        ymin = min(ymin, y);
        ymax = max(ymax, y);
    }
    return (xmax-xmin) * (ymax-ymin);
}

int main(){
    int n;
    cin >> n;
    vector<pair<i64, i64>> v;
    vector<int> dir;
    for(int i=0;i<n;++i){
        i64 x, y;
        char c;
        cin >> x >> y >> c;
        v.emplace_back(x, y);
        int d;
        if(c == 'U')d = 0;
        else if(c == 'R')d = 1;
        else if(c == 'D')d = 2;
        else d = 3;
        dir.push_back(d);
    }

    double left = 0, right = 1e9, phi = (1.0+sqrt(5))/2.0;
    for(int i=0;i<100;++i){
        double t1 = (phi*left + right) / (1.0+phi);
        double t2 = (left + phi * right) / (1.0+phi);
        if(f(t1, v, dir) > f(t2, v, dir))left = t1;
        else right = t2;
    }
    printf("%.10f\n", f(left, v, dir));

    return 0;
}
