N = int(input())
if N%90 == 0:
    if (N//90)%2 == 1:
        print("Yes")
    else:
        print("No")
else:
    print("No")