{
TASK:flower
LANG:PASCAL
}
var
  n,ns,we:longint;

function f1(n,s:longint):longint;
var
  res:longint;
begin
   if n<s then begin writeln('error');halt;end;
   if s=0 then exit(1);
   if n>s then f1:=f1(n-1,s)+f1(n,s-1)
   else f1:=f1(n,s-1);

end;

function f2(f,s:longint):longint;
begin
  if (f=0) then exit(1);
  if (s=0) then exit(1);
  f2:=f2(f-1,s)+f2(f,s-1);
end;

procedure inp;
var
   i:longint;
   ch:char;
begin
   readln(n);
   for i:=1 to n do
   begin
     read(ch);
     if (ch='W')or(ch='E') then inc(we) else inc(NS);
     read(ch);
   end;
end;
begin
   inp;
   writeln(f1(ns div 2,ns div 2)*f1(we div 2,we div 2)*f2(ns,we)-1);
end.
