main = do
    n <- readLn :: IO Int
    as <- map read . words <$> getLine :: IO [Int]
    let s = sum $ map f as
    print s

f a = f' 0 a
    where f' k a | odd a = k
                 | even a = f' (k+1) (a `div` 2)