let find_opt p l =
  try Some (List.find p l) with
  | Not_found -> None

let () =
  let n = Scanf.scanf "%d\n" (fun n -> n) in
  let ss = Scanf.scanf "%s\n" (fun s ->
    Array.init n (fun i ->
      match s.[i] with
      | 'o' -> 1
      | 'x' -> -1)) in
  let ss' =
    Array.to_list (Array.init (n - 2) (fun i -> ss.(i + 1))) in
  [[1; 1]; [1; -1]; [-1; 1]; [-1; -1]]
  |> List.map (fun init ->
      List.fold_left (fun ((t_n :: t_n_1 :: _) as ts) s ->
        s * t_n * t_n_1 :: ts) init ss'
      |> List.rev
      |> Array.of_list)
  |> find_opt (fun ts ->
      ts.(n - 2) * ts.(n - 1) * ts.(0) = ss.(n - 1)
      && ts.(n - 1) * ts.(0) * ts.(1) = ss.(0))
  |> (function
        | None -> "-1"
        | Some ts ->
            String.init n (fun i ->
              match ts.(i) with
              | 1 -> 'S'
              | -1 -> 'W'))
  |> print_endline
