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

int l=0, r=0, u=0, d=0, sx=0, sy=0;
long l1=1e9, l2=-1e9;
long r1=1e9, r2=-1e9;
long u1=1e9, u2=-1e9;
long d1=1e9, d2=-1e9;
long sx1=1e9, sx2=-1e9;
long sy1=1e9, sy2=-1e9;
long min_area = 1e18;

long area(long t){
    long dl1 = l1 - t;
    long dl2 = l2 - t;
    long dr1 = r1 + t;
    long dr2 = r2 + t;
    long dd1 = d1 - t;
    long dd2 = d2 - t;
    long du1 = u1 + t;
    long du2 = u2 + t;
    long x1=1e18, x2=-1e18;
    long y1=1e18, y2=-1e18;
    if(sx) x1 = min(x1, sx1);
    if(l) x1 = min(x1, dl1);
    if(r) x1 = min(x1, dr1);
    if(sx) x2 = max(x2, sx2);
    if(l) x2 = max(x2, dl2);
    if(r) x2 = max(x2, dr2);
    if(sy) y1 = min(y1, sy1);
    if(u) y1 = min(y1, du1);
    if(d) y1 = min(y1, dd1);
    if(sy) y2 = max(y2, sy2);
    if(u) y2 = max(y2, du2);
    if(d) y2 = max(y2, dd2);
   return (x2 - x1)*(y2 - y1); 
}

void f(long a, long b, long s){
    long dist = a - b;
    if(dist >= 0){
        long t = dist / s;
        min_area = min(min_area, area(t));
    }
}

void Main()
{
    long n, x, y;
    char c;
    cin >> n;
    for (int i = 0; i < n; i++)
    {
        cin >> x >> y >> c;
        switch(c){
        case 'L':
            l1 = min(l1, x);
            l2 = max(l2, x);
            sy1 = min(sy1, y);
            sy2 = max(sy2, y);
            l = 1;
            sy = 1;
            break;
        case 'R':
            r1 = min(r1, x);
            r2 = max(r2, x);
            sy1 = min(sy1, y);
            sy2 = max(sy2, y);
            r = 1;
            sy = 1;
            break;
        case 'U':
            u1 = min(u1, y);
            u2 = max(u2, y);
            sx1 = min(sx1, x);
            sx2 = max(sx2, x);
            u = 1;
            sx = 1;
            break;
        case 'D':
            d1 = min(d1, y);
            d2 = max(d2, y);
            sx1 = min(sx1, x);
            sx2 = max(sx2, x);
            d = 1;
            sx = 1;
            break;
        }
    }
    l1 *= 2;
    l2 *= 2;
    r1 *= 2;
    r2 *= 2;
    u1 *= 2;
    u2 *= 2;
    d1 *= 2;
    d2 *= 2;
    sx1 *= 2;
    sx2 *= 2;
    sy1 *= 2;
    sy2 *= 2;
    min_area = area(0);
    if(l && r){
        f(l1, r1, 2); 
        f(l1, r2, 2); 
        f(l2, r1, 2); 
        f(l2, r2, 2);
    }
    if(l && sx){
        f(l1, sx1, 1);
        f(l1, sx2, 1);
        f(l2, sx1, 1);
        f(l2, sx2, 1);
    }
    if(r && sx){
        f(sx1, r1, 1);
        f(sx2, r1, 1);
        f(sx1, r2, 1);
        f(sx2, r2, 1);
    }
    if(u && d){
        f(d1, u1, 2); 
        f(d1, u2, 2); 
        f(d2, u1, 2); 
        f(d2, u2, 2);
    } 
    if(u && sy){
        f(sy1, u1, 1);
        f(sy2, u1, 1);
        f(sy1, u2, 1);
        f(sy2, u2, 1);
    }
    if(d && sy){
        f(d1, sy1, 1);
        f(d1, sy2, 1);
        f(d2, sy1, 1);
        f(d2, sy2, 1);
    }
    
    // cout << fixed << setprecision(15) << min_area << endl;
    cout << min_area/4;
    switch(min_area % 4){
    case 3:
        cout << ".75";
        break;
    case 2:
        cout << ".5";
        break;
    case 1:
        cout << ".25";
        break;
    }
    cout << endl;
    
}

int main(int argc, char **argv)
{
    Main();
    return 0;
}


Measured memory_bytes: 256