t = int(input()) imp_n = (2,3,5,6,8,11,14) #无法到达的n值 for _ in range(t): n = int(input()) if n in imp_n: print('No') else: print('Yes')