{-# OPTIONS_GHC -O #-}

import Control.Monad
import Data.List
import qualified Data.ByteString.Lazy.Char8 as B

readIntL :: IO [Int]
readIntL = unfoldr(B.readInt.B.dropWhile(==' '))<$>B.getContents

f (a,b,c) n
    | odd n = (a+1,b,c)
    | n `mod` 4 == 0 = (a,b,c+1)
    | True = (a,1,c)

main=do
    n <- readLn
    (a,b,c) <- foldl' f (0,0,0).take n <$> readIntL
    putStrLn $ if a+b <= c+1 then "Yes" else "No"
