main = getLine >> interact (f 0 0 0 . map read . words)

f x y z []
  | y + 2 > x + t = "Yes"
  | otherwise = "No"
    where t = if z > 0 then 1 else 0
f x y z (a:as)
  | odd a = f (succ x) y z as
  | a `mod` 4 == 0 = f x (succ y) z as
  | otherwise = f x y (succ z) as