#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include <fstream>
#include <iostream>
#include <algorithm>
#include <bitset>
#include <array>
#include <vector>
#include <queue>
#include <set>
#include <cmath> // 変数名にy1が使えなくなるかも…。
#include <map>
#include <unordered_map>
#include <unordered_set>
#include <string>

#define REP(i,n) for(ll i = 0; i < (ll)n; i++)
#define INF 1000000000000000
using namespace std;
typedef long long ll;
typedef double db;
typedef string str;
typedef pair<ll,ll> p; //後半は0で増加・1で平坦・2で減少
 
struct pos{
  vector<ll> points[3];
  void add_point(p point){
    points[point.second].push_back(point.first);
  }
  void points_sort(){
    REP(i,3) sort(points[i].begin(),points[i].end());
  }
  vector<double> times(){
    points_sort();
    vector<double> res;
    res.push_back(0);
    if(!points[0].empty()&&!points[1].empty()&&(points[0].front()<points[1].front()))
    res.push_back(points[1].front()-points[0].front());
    if(!points[1].empty()&&!points[2].empty()&&(points[1].front()<points[2].front()))
    res.push_back(points[2].front()-points[1].front());
    if(!points[0].empty()&&!points[2].empty()&&(points[0].front()<points[2].front()))
    res.push_back((points[2].front()-points[0].front())*1.0/2);
    if(!points[0].empty()&&!points[1].empty()&&(points[0].back()<points[1].back()))
    res.push_back(points[1].back()-points[0].back());
    if(!points[1].empty()&&!points[2].empty()&&(points[1].back()<points[2].back()))
    res.push_back(points[2].back()-points[1].back());
    if(!points[0].empty()&&!points[2].empty()&&(points[0].back()<points[2].back()))
    res.push_back((points[2].back()-points[0].back())*1.0/2);
    return res;
  }
  double min_pos(double t){
    double res = INF;
    if(!points[0].empty()) res = min(res, points[0].front()+t);
    if(!points[1].empty()) res = min(res, (double) points[1].front());
    if(!points[2].empty()) res = min(res, points[2].front()-t);
    return res;
  }
  double max_pos(double t){
    double res = -INF;
    if(!points[0].empty()) res = max(res, points[0].back()+t);
    if(!points[1].empty()) res = max(res, (double) points[1].back());
    if(!points[2].empty()) res = max(res, points[2].back()-t);
    return res;
  }
};

typedef __int128_t int128_t;
std::istream &operator>>(std::istream& input, int128_t& value) { // int128_tの入力。入力が64bitに収まる前提。
    long long tmp; input >> tmp; value = tmp;
    return input;
}
std::ostream &operator<<(std::ostream& output, const int128_t value) { // int128_tの出力。出力が64bitに収まる前提。
    output << (long long)value;
    return output;
}

const int MAX_N = 100050;
int N;
int128_t x[MAX_N], y[MAX_N];
char d[MAX_N];

std::vector<double> t_vec;

std::pair<double, double> calc_bound(double t, std::vector<double>& vd, std::vector<double>& vc, std::vector<double>& vi) {
    //double max = std::numeric_limits<double>::min();
    double min = std::numeric_limits<double>::max();
    double max = -min;

    for (auto v : vd) {
        min = std::min(min, v - t);
        max = std::max(max, v - t);
    }
    for (auto v : vc) {
        min = std::min(min, v);
        max = std::max(max, v);
    }
    for (auto v : vi) {
        min = std::min(min, v + t);
        max = std::max(max, v + t);
    }
    return std::pair<double, double>({min, max});
}

void set_time(std::vector<double>& vd, std::vector<double>& vc, std::vector<double>& vi) {
    t_vec.push_back(0);
    if (0 < vd.size() && 0 < vi.size()) {
        if (vi[0] < vd[0]) {
            double tmp = vd[0] - vi[0];
            t_vec.push_back(tmp / 2);
        }
        if (vi.back() < vd.back()) {
            double tmp = vd.back() - vi.back();
            t_vec.push_back(tmp / 2);
        }
    }
    if (0 < vd.size() && 0 < vc.size()) {
        if (vc[0] < vd[0]) {
            t_vec.push_back(vd[0] - vc[0]);
        }
        if (vc.back() < vd.back()) {
            t_vec.push_back(vd.back() - vc.back());
        }
    }
    if (0 < vi.size() && 0 < vc.size()) {
        if (vi[0] < vc[0]) {
            t_vec.push_back(vc[0] - vi[0]);
        }
        if (vi.back() < vc.back()) {
            t_vec.push_back(vc.back() - vi.back());
        }
    }
}

int main(int argc, char **argv) {
    std::cin >> N;
    pos X, Y;
    for (int i = 1; i <= N; i++) {
        std::cin >> x[i] >> y[i] >> d[i];
    }

    std::vector<double> x_d, x_c, x_i;
    std::vector<double> y_d, y_c, y_i;
    
    //t_vec.push_back(0);
    
    for (int i = 1; i <= N; i++) {
        if (d[i] == 'L') {
            x_d.push_back(x[i]);
            y_c.push_back(y[i]);

            X.add_point(p(x[i],2));
            Y.add_point(p(y[i],1));
        } else if (d[i] == 'R') {
            x_i.push_back(x[i]);
            y_c.push_back(y[i]);

            X.add_point(p(x[i],0));
            Y.add_point(p(y[i],1));
        } else if (d[i] == 'U') {
            x_c.push_back(x[i]);
            y_i.push_back(y[i]);

            X.add_point(p(x[i],1));
            Y.add_point(p(y[i],0));
        } else {
            x_c.push_back(x[i]);
            y_d.push_back(y[i]);

            X.add_point(p(x[i],1));
            Y.add_point(p(y[i],2));
        }
    }

    vector<double> times;
    for(double tv: X.times()) times.push_back(tv);
    for(double tv: Y.times()) times.push_back(tv);

    std::sort(x_d.begin(), x_d.end());
    std::sort(x_i.begin(), x_i.end());
    std::sort(x_c.begin(), x_c.end());

    std::sort(y_d.begin(), y_d.end());
    std::sort(y_i.begin(), y_i.end());
    std::sort(y_c.begin(), y_c.end());

    set_time(x_d, x_c, x_i);
    set_time(y_d, y_c, y_i);

    //std::cout << t_vec.size() << " " << times.size() << std::endl;
    assert(t_vec.size() == times.size());
    double tsum1 = 0;
    double tsum2 = 0;
    for (int i = 0; i < t_vec.size(); i++) {
        tsum1 += t_vec[i];
        tsum2 += times[i];
    }
    assert(abs(tsum2 - tsum1) < 1e-9);

    //std::sort(t_vec.begin(), t_vec.end());
    //t_vec.erase(std::unique(t_vec.begin(), t_vec.end()), t_vec.end());

    double ret = std::numeric_limits<double>::max();
    double ans = 1e30;
    for (double t : t_vec) {
    //for (double t : times) {
        auto bx = calc_bound(t, x_d, x_c, x_i);
        auto by = calc_bound(t, y_d, y_c, y_i);
        //std::cout << t << " " << bx.second << " " << bx.first << " " << by.second << " " << by.first << std::endl;
        assert(abs(bx.second - X.max_pos(t)) < 1e-9);
        assert(abs(bx.first - X.min_pos(t)) < 1e-9);
        assert(abs(by.second - Y.max_pos(t)) < 1e-9);
        assert(abs(by.first - Y.min_pos(t)) < 1e-9);
        ans = min(ans,(X.max_pos(t)-X.min_pos(t))*(Y.max_pos(t)-Y.min_pos(t)));
        ret = std::min(ret, (bx.second - bx.first) * (by.second - by.first));
        assert(abs(ans - ret) < 1e-9);
        //std::cout << ans << " " << ret << std::endl;
    }

    printf("%.10f\n", ret);
    //std::cout << ans << std::endl;


    return 0;
}

Measured memory_bytes: 7260