package main

import (
	"bufio"
	"fmt"
	"math"
	"os"
	"strconv"
)

func getScanner(fp *os.File) *bufio.Scanner {
	scanner := bufio.NewScanner(fp)
	scanner.Split(bufio.ScanWords)
	scanner.Buffer(make([]byte, 500001), 500000)
	return scanner
}

func getNextString(scanner *bufio.Scanner) string {
	scanner.Scan()
	return scanner.Text()
}

func getNextInt(scanner *bufio.Scanner) int {
	i, _ := strconv.Atoi(getNextString(scanner))
	return i
}

func getNextInt64(scanner *bufio.Scanner) int64 {
	i, _ := strconv.ParseInt(getNextString(scanner), 10, 64)
	return i
}

func getNextUint64(scanner *bufio.Scanner) uint64 {
	i, _ := strconv.ParseUint(getNextString(scanner), 10, 64)
	return i
}

func getNextFloat64(scanner *bufio.Scanner) float64 {
	i, _ := strconv.ParseFloat(getNextString(scanner), 64)
	return i
}

func main() {
	fp := os.Stdin
	wfp := os.Stdout

	if os.Getenv("MASPY") == "ますピ" {
		fp, _ = os.Open(os.Getenv("BEET_THE_HARMONY_OF_PERFECT"))
	}
	if os.Getenv("MASPYPY") == "ますピッピ" {
		wfp, _ = os.Create(os.Getenv("NGTKANA_IS_GENIUS10"))
	}

	scanner := getScanner(fp)
	writer := bufio.NewWriter(wfp)

	n := getNextInt(scanner)
	dx := map[string]int{
		"L": 0,
		"R": 2,
		"U": 1,
		"D": 1,
	}
	dy := map[string]int{
		"L": 1,
		"R": 1,
		"U": 2,
		"D": 0,
	}
	xx := make([][2]float64, 3)
	yy := make([][2]float64, 3)

	for i := 0; i < 3; i++ {
		xx[i][0] = math.MaxFloat64
		yy[i][0] = math.MaxFloat64
		xx[i][1] = -math.MaxFloat64
		yy[i][1] = -math.MaxFloat64
	}
	for i := 0; i < n; i++ {
		x := getNextFloat64(scanner)
		y := getNextFloat64(scanner)
		d := getNextString(scanner)
		if xx[dx[d]][0] > x {
			xx[dx[d]][0] = x
		}
		if xx[dx[d]][1] < x {
			xx[dx[d]][1] = x
		}
		if yy[dy[d]][0] > y {
			yy[dy[d]][0] = y
		}
		if yy[dy[d]][1] < y {
			yy[dy[d]][1] = y
		}
	}

	ans := calc(0, xx, yy)

	for i := 0; i < 3; i++ {
		for j := 0; j < i; j++ {
			for ii := 0; ii < 2; ii++ {
				for jj := 0; jj < 2; jj++ {
					if xx[j][ii] == math.MaxFloat64 {
						continue
					}
					if xx[i][jj] == math.MaxFloat64 {
						continue
					}
					if xx[j][ii] == -math.MaxFloat64 {
						continue
					}
					if xx[i][jj] == -math.MaxFloat64 {
						continue
					}
					t := (xx[j][ii] - xx[i][jj]) / float64(i-j)
					if t < 0 {
						continue
					}
					a := calc(t, xx, yy)
					if ans > a {
						ans = a
					}
				}
			}
			for ii := 0; ii < 2; ii++ {
				for jj := 0; jj < 2; jj++ {
					if yy[j][ii] == math.MaxFloat64 {
						continue
					}
					if yy[j][ii] == -math.MaxFloat64 {
						continue
					}
					if yy[i][jj] == math.MaxFloat64 {
						continue
					}
					if yy[i][jj] == -math.MaxFloat64 {
						continue
					}
					t := (yy[j][ii] - yy[i][jj]) / float64(i-j)
					if t < 0 {
						continue
					}
					a := calc(t, xx, yy)
					if ans > a {
						ans = a
					}
				}
			}
		}
	}

	fmt.Fprintln(writer, ans)
	writer.Flush()
}

func calc(t float64, xx, yy [][2]float64) float64 {
	mx0 := math.MaxFloat64
	my0 := math.MaxFloat64
	mx1 := -math.MaxFloat64
	my1 := -math.MaxFloat64
	for i := 0; i < 3; i++ {
		if xx[i][0] < math.MaxFloat64 && mx0 > xx[i][0]+t*float64(i) {
			mx0 = xx[i][0] + t*float64(i)
		}
		if xx[i][1] > -math.MaxFloat64 && mx1 < xx[i][1]+t*float64(i) {
			mx1 = xx[i][1] + t*float64(i)
		}
		if yy[i][0] < math.MaxFloat64 && my0 > yy[i][0]+t*float64(i) {
			my0 = yy[i][0] + t*float64(i)
		}
		if yy[i][1] > -math.MaxFloat64 && my1 < yy[i][1]+t*float64(i) {
			my1 = yy[i][1] + t*float64(i)
		}
	}

	return (mx1 - mx0) * (my1 - my0)
}


Measured memory_bytes: 4352