// Original C++ solution (slower):
#include<iostream>

#define _USE_MATH_DEFINES

#include<math.h>

#include<vector>

#include<array>

#include<algorithm>

#include<numeric>

#include<map>

#include<stack>

#include<queue>

#include<deque>

#include<set>

#include<cstdio>

#include<cstring>

#include<string>

using namespace std;

typedef long long ll;

typedef long double ld;

typedef vector<ld> vec;

typedef vector<vec> mat;

typedef pair<ll,ll> P;

typedef map<ll,ll> MP;

typedef priority_queue<ll> PQ;

typedef stack<ll> ST;

typedef queue<ll> QUE;

#define pb push_back

#define st first

#define nd second

#define SZ(x) ((int)(x).size())

#define FOR(i,s,n) for(int i=(int)(s); i< (int)(n); i++)

#define rep(i,n) FOR(i,0,n)

#define all(x) (x).begin(),(x).end()

#define each(x,c) for(auto x: (c))

#define LB(x,a) lower_bound(all(x), a)

#define UB(x,a) upper_bound(all(x), a)

const ll mod=1e9+7;

const ld INF=1.0e30L;

const ld EPS=1.0e-15L;

const double PI=M_PI;



vec min_x(3),max_x(3),min_y(3),max_y(3);

ld f(ld T){

    ld Mx=max(max_x[0],max(max_x[1]+T,max_x[2]-T));

    ld mx=min(min_x[0],min(min_x[1]+T,min_x[2]-T));

    ld My=max(max_y[0],max(max_y[1]+T,max_y[2]-T));

    ld my=min(min_y[0],min(min_y[1]+T,min_y[2]-T));

    return (Mx-mx)*(My-my);

}



int main(){

    int N; cin>>N;

    mat X(3),Y(3);

    rep(i,N){

        ld x,y; cin>>x>>y;

        char d; cin>>d;

        if(d=='U'){

            X[0].pb(x); Y[1].pb(y);

        }

        if(d=='D'){

            X[0].pb(x); Y[2].pb(y);

        }

        if(d=='R'){

            X[1].pb(x); Y[0].pb(y);

        }

        if(d=='L'){

            X[2].pb(x); Y[0].pb(y);

        }

    }

    rep(i,3){

        if(X[i].empty()){

            min_x[i]=INF; max_x[i]=-INF;

        }

        else{

            sort(all(X[i])); 

            min_x[i]=X[i][0]; max_x[i]=X[i][SZ(X[i])-1];

        }

        if(Y[i].empty()){

            min_y[i]=INF; max_y[i]=-INF;

        }

        else{

            sort(all(Y[i]));

            min_y[i]=Y[i][0]; max_y[i]=Y[i][SZ(Y[i])-1];

        }

    }

    int count=0;

    ld l=0.0L,r=1.0e10L;

    while(count<500){

        ld m1=(2.0L*l+r)/3.0L, m2=(l+2.0L*r)/3.0L;

        if(f(m1)<f(m2)) r=m2;

        else            l=m1;

        count++;

    }

    printf("%.15Lf\n",f(l));

    return 0;

}

// Optimized solution to the same problem (faster):
#include<iostream>

#define _USE_MATH_DEFINES

#include<math.h>

#include<vector>

#include<array>

#include<algorithm>

#include<numeric>

#include<map>

#include<stack>

#include<queue>

#include<deque>

#include<set>

#include<cstdio>

#include<cstring>

#include<string>

using namespace std;

typedef long long ll;

typedef long double ld;

typedef vector<ld> vec;

typedef vector<vec> mat;

typedef pair<ll,ll> P;

typedef map<ll,ll> MP;

typedef priority_queue<ll> PQ;

typedef stack<ll> ST;

typedef queue<ll> QUE;

#define pb push_back

#define st first

#define nd second

#define SZ(x) ((int)(x).size())

#define FOR(i,s,n) for(int i=(int)(s); i< (int)(n); i++)

#define rep(i,n) FOR(i,0,n)

#define all(x) (x).begin(),(x).end()

#define each(x,c) for(auto x: (c))

#define LB(x,a) lower_bound(all(x), a)

#define UB(x,a) upper_bound(all(x), a)

const ll mod=1e9+7;

const ld INF=1.0e30L;

const ld EPS=1.0e-15L;

const double PI=M_PI;



vec min_x(3),max_x(3),min_y(3),max_y(3);

ld f(ld T){

    ld Mx=max(max_x[0],max(max_x[1]+T,max_x[2]-T));

    ld mx=min(min_x[0],min(min_x[1]+T,min_x[2]-T));

    ld My=max(max_y[0],max(max_y[1]+T,max_y[2]-T));

    ld my=min(min_y[0],min(min_y[1]+T,min_y[2]-T));

    return (Mx-mx)*(My-my);

}



int main(){

    int N; cin>>N;

    mat X(3),Y(3);

    rep(i,N){

        ld x,y; cin>>x>>y;

        char d; cin>>d;

        if(d=='U'){

            X[0].pb(x); Y[1].pb(y);

        }

        if(d=='D'){

            X[0].pb(x); Y[2].pb(y);

        }

        if(d=='R'){

            X[1].pb(x); Y[0].pb(y);

        }

        if(d=='L'){

            X[2].pb(x); Y[0].pb(y);

        }

    }

    rep(i,3){

        if(X[i].empty()){

            min_x[i]=INF; max_x[i]=-INF;

        }

        else{

            sort(all(X[i])); 

            min_x[i]=X[i][0]; max_x[i]=X[i][SZ(X[i])-1];

        }

        if(Y[i].empty()){

            min_y[i]=INF; max_y[i]=-INF;

        }

        else{

            sort(all(Y[i]));

            min_y[i]=Y[i][0]; max_y[i]=Y[i][SZ(Y[i])-1];

        }

    }

    ld T,ans=f(0.0L);

    rep(i,2){

        T=fabs(max_x[i+1]-max_x[0]);

        ans=min(ans,f(T));

        T=fabs(max_y[i+1]-max_y[0]);

        ans=min(ans,f(T));

        T=fabs(min_x[i+1]-min_x[0]);

        ans=min(ans,f(T));

        T=fabs(min_y[i+1]-min_y[0]);

        ans=min(ans,f(T));        

    }

    T=fabs(max_x[2]-max_x[1])/2.0L;

    ans=min(ans,f(T));

    T=fabs(max_y[2]-max_y[1])/2.0L;

    ans=min(ans,f(T));

    T=fabs(min_x[2]-min_x[1])/2.0L;

    ans=min(ans,f(T));

    T=fabs(min_y[2]-min_y[1])/2.0L;

    ans=min(ans,f(T)); 

    printf("%.15Lf\n",ans);

    return 0;

}

// Fastest known solution for this problem: