defmodule Main do def main do 1..(IO.read(:line) |> String.trim() |> String.to_integer()) |> Enum.map(fn _ -> IO.read(:line) |> String.trim() |> String.to_integer() end) |> solve |> IO.puts() end def solve(x) do solve_rec(x, true, 0) end def solve_rec([], i, _) do cond do i -> "T" true -> "F" end end def solve_rec(x, i, l) do cond do ((x |> hd) - l) |> abs != 1 -> "F" true -> solve_rec(x |> tl, i, x |> hd) end end end