# import numpy as np
import math
N = int(input())
a = list(map(int, input().split()))

two_count = 0
four_count = 0
for i in a:
    if i >= 4 and i % 4 == 0:
        four_count += 1
    elif i >= 2 and i % 2 == 0:
        two_count += 1

check = len(a) - two_count
if two_count > 0:
    ans = "YES" if math.ceil(check/2) <= four_count else "NO"
else:
    if check == 2:
        ans = "YES" if 1 <= four_count else "NO"
    else:
        ans = "YES" if check - 2 <= four_count else "NO"
print(ans)