main :: IO ()
main = do
    input <- getLine
    let (santa1Dirs, santa2Dirs) = splitDirections input
        housesSanta1 = step santa1Dirs [(0,0)]
        housesSanta2 = step santa2Dirs [(0,0)]
        combinedHouses = length $ nub $ housesSanta1 ++ housesSanta2
    putStrLn (show combinedHouses)
main :: IO ()
main = do
    input <- getLine
    let (santa1Dirs, santa2Dirs) = splitDirections input
        housesSanta1 = step santa1Dirs [(0,0)]
        housesSanta2 = step santa2Dirs [(0,0)]
        combinedHouses = length $ nub $ housesSanta1 ++ housesSanta2
    putStrLn (show combinedHouses)
main = do
    input <- getLine
    let (santa1Dirs, santa2Dirs) = splitDirections input
        housesSanta1 = step santa1Dirs [(0,0)]
        housesSanta2 = step santa2Dirs [(0,0)]
        combinedHouses = length $ nub $ housesSanta1 ++ housesSanta2
    putStrLn (show combinedHouses)