open Printf
open Scanf


let rec ch str chr idx =
  if idx < String.length str then
    (if (String.get str idx = chr) then true else ch str chr (idx + 1))
  else false
    
let _ =
  let s = scanf "%s\n" (fun x -> x) in
  match List.map (fun x -> (ch s x 0)) ['N'; 'E'; 'S'; 'W'] with
  | [true; false; true; false] | [false; true; false; true] | [true; true; true; true] -> printf "Yes\n"
  | _ -> printf "No\n"
