{-# OPTIONS_GHC -O2 #-}
{-# LANGUAGE BangPatterns          #-}
{-# LANGUAGE CPP                   #-}
{-# LANGUAGE LambdaCase            #-}
{-# LANGUAGE MagicHash             #-}
{-# LANGUAGE MultiParamTypeClasses #-}
{-# LANGUAGE MultiWayIf            #-}
{-# LANGUAGE OverloadedStrings     #-}
{-# LANGUAGE RecordWildCards       #-}
{-# LANGUAGE TupleSections         #-}
{-# LANGUAGE TypeFamilies          #-}
{-# LANGUAGE ViewPatterns          #-}

import           Control.Applicative
import           Control.Exception
import           Control.Monad
import           Control.Monad.Primitive
import           Control.Monad.ST
import           Control.Monad.State.Strict
import           Data.Bool
import qualified Data.ByteString             as B
import qualified Data.ByteString.Char8       as C
import qualified Data.ByteString.Unsafe      as B
import           Data.Char
import qualified Data.Foldable               as F
import           Data.Function
import qualified Data.IntMap.Strict          as IM
import qualified Data.IntSet                 as IS
import qualified Data.List                   as L
import qualified Data.Map.Strict             as M
import           Data.Monoid                 hiding (First(..))
import           Data.Ord
import           Data.Primitive.MutVar
import qualified Data.Set                    as S
import           Data.Tuple
import qualified Data.Vector                 as V
import qualified Data.Vector.Mutable         as VM
import qualified Data.Vector.Generic         as G
import qualified Data.Vector.Generic.Mutable as GM
import qualified Data.Vector.Unboxed         as U
import qualified Data.Vector.Unboxed.Mutable as UM
import           Debug.Trace
import           Foreign                     hiding (void)
import           GHC.Exts
import           Unsafe.Coerce

main :: IO ()
main = do
    n <- readLn :: IO Int
    es <- U.map(\(x, y)->(x-1, y-1))
        . U.unfoldrN (n - 1) parseInt2 <$> C.getContents
    print $ solve n es

data Answer = First | Second deriving Show

solve :: Int -> U.Vector (Int, Int) -> Answer
solve n es
    | diameter gr `mod` 3 == 1 = Second
    | otherwise = First
  where
    gr = undirectedWGraph (U.replicate n ()) $ U.map (\(x, y) -> (x, y, 1))es

type VertexId = Int
type EdgeId = Int
type Vertex = ()
type Edge = (Int, Int)
type WEdge = (Int, Int, Int)

data Graph v e = Graph
    { adjacent :: V.Vector (U.Vector EdgeId)
    , vertices :: U.Vector v
    , edges :: U.Vector e
    }

undirectedWGraph
    :: (U.Unbox v)
    => U.Vector v -> U.Vector (Int, Int, Int) -> Graph v WEdge
undirectedWGraph vs es = runST $ do
    outDeg <- UM.replicate numV 0
    U.forM_ es $ \(x, y, _) -> do
        UM.unsafeModify outDeg (+1) x
        UM.unsafeModify outDeg (+1) y
    offset <- U.prescanl' (+) 0 <$> U.freeze outDeg
    mpos <- U.thaw offset
    mbuf <- UM.unsafeNew numE
    ues <- UM.unsafeNew numE
    flip U.imapM es $ \i (x, y, d) -> do
        let !ex = 2 * i
        let !ey = 2 * i + 1
        UM.unsafeWrite ues ex (x, y, d)
        UM.unsafeWrite ues ey (y, x, d)

        ox <- UM.unsafeRead mpos x
        UM.unsafeWrite mbuf ox ex
        UM.unsafeModify mpos (+1) x
        oy <- UM.unsafeRead mpos y
        UM.unsafeWrite mbuf oy ey
        UM.unsafeModify mpos (+1) y
    buf <- U.freeze mbuf

    adj <- V.generateM numV $ \i -> do
        let o = U.unsafeIndex offset i
        p <- UM.unsafeRead mpos i
        return $! U.unsafeSlice o (p - o) buf
    Graph adj vs <$> U.unsafeFreeze ues
  where
    numV = U.length vs
    numE = 2 * U.length es

shortestPath :: (U.Unbox v) => Graph v WEdge -> VertexId -> U.Vector Int
shortestPath Graph{..} root = U.create $ do
    dist <- UM.unsafeNew (U.length vertices)
    UM.unsafeWrite dist root 0
    stack <- newStackM
    U.forM_ (V.unsafeIndex adjacent root) $ \rootE ->
        pushM rootE stack

    fix $ \loop ->
        popM stack >>= \case
            Just ei -> do
                let (p, v, d) = U.unsafeIndex edges ei
                UM.unsafeRead dist p >>= UM.unsafeWrite dist v . (+d)
                let nexts = U.filter (/= xor 1 ei) $ V.unsafeIndex adjacent v
                U.forM_ nexts $ \i ->
                    pushM i stack
                loop
            Nothing -> return ()
    return dist

diameter :: (U.Unbox v) => Graph v WEdge -> Int
diameter tree = U.maximum
    . shortestPath tree
    . U.maxIndex
    $ shortestPath tree 0

height :: (U.Unbox v) => Graph v WEdge -> U.Vector Int
height tree = U.zipWith max fromS fromT
  where
    s = U.maxIndex $ shortestPath tree 0
    fromS = shortestPath tree s
    t = U.maxIndex fromS
    fromT = shortestPath tree t

data VecStack m a = VecStack
    { stackInfo :: !(UM.MVector m Int)
    , stackData :: !(UM.MVector m a)
    }

newStackM :: (PrimMonad m, U.Unbox a) => m (VecStack (PrimState m) a)
newStackM = VecStack <$> UM.replicate 1 0 <*> UM.unsafeNew (1024 * 1024)

popM :: (PrimMonad m, U.Unbox a) => VecStack (PrimState m) a -> m (Maybe a)
popM (VecStack info s) = do
    len <- UM.unsafeRead info 0
    if len > 0
    then do
        UM.unsafeWrite info 0 (len - 1)
        pure <$> UM.unsafeRead s (len - 1)
    else return Nothing
{-# INLINE popM #-}

pushM :: (PrimMonad m, U.Unbox a) => a -> VecStack (PrimState m) a -> m ()
pushM x (VecStack info s) = do
    len <- UM.unsafeRead info 0
    UM.unsafeWrite s len x
    UM.unsafeWrite info 0 (len + 1)
{-# INLINE pushM #-}

-------------------------------------------------------------------------------
type Parser a = C.ByteString -> Maybe (a, C.ByteString)

parseInt :: Parser Int
parseInt = C.readInt . C.dropWhile isSpace

parseInt2 :: Parser (Int, Int)
parseInt2 = runStateT $
    (,) <$> StateT (C.readInt . C.dropWhile isSpace)
        <*> StateT (C.readInt . B.unsafeTail)

parseInt3 :: Parser (Int, Int, Int)
parseInt3 = runStateT $
    (,,) <$> StateT (C.readInt . C.dropWhile isSpace)
        <*> StateT (C.readInt . B.unsafeTail)
        <*> StateT (C.readInt . B.unsafeTail)

parseInt4 :: Parser (Int, Int, Int, Int)
parseInt4 = runStateT $
    (,,,) <$> StateT (C.readInt . C.dropWhile isSpace)
        <*> StateT (C.readInt . B.unsafeTail)
        <*> StateT (C.readInt . B.unsafeTail)
        <*> StateT (C.readInt . B.unsafeTail)