#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ scanf(char *, ...);
int main() {
  int n, i;
  int ara[200000];
  char ch;
  scanf("%d", &n);
  for (i = 0; i < n - 1; i++) {
    scanf("%d", &ara[i]);
    scanf("%c", &ch);
  }
  scanf("%d", &ara[i]);
  for (i = 0; i < n; i++) {
    if (ara[i] == 2 || ara[i] == 3 || ara[i] == 5 || ara[i] == 7 ||
        ara[i] == 13 || ara[i] == 17 || ara[i] == 19 || ara[i] == 31)
      printf("Yes\n");
    else
      printf("No\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0xc3520,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xec7(%rip),%rdi
lea    -0x8(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x0,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    -0x8(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jge    119f <main+0x7f>
movslq -0xc(%rbp),%rax
lea    -0xc3510(%rbp),%rsi
shl    $0x2,%rax
add    %rax,%rsi
lea    0xe8b(%rip),%rdi
mov    $0x0,%al
call   1040 <scanf@plt>
lea    0xe80(%rip),%rdi
lea    -0xc3511(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    114b <main+0x2b>
movslq -0xc(%rbp),%rax
lea    -0xc3510(%rbp),%rsi
shl    $0x2,%rax
add    %rax,%rsi
lea    0xe48(%rip),%rdi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x0,-0xc(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1292 <main+0x172>
movslq -0xc(%rbp),%rax
cmpl   $0x2,-0xc3510(%rbp,%rax,4)
02
je     1262 <main+0x142>
movslq -0xc(%rbp),%rax
cmpl   $0x3,-0xc3510(%rbp,%rax,4)
03
je     1262 <main+0x142>
movslq -0xc(%rbp),%rax
cmpl   $0x5,-0xc3510(%rbp,%rax,4)
05
je     1262 <main+0x142>
movslq -0xc(%rbp),%rax
cmpl   $0x7,-0xc3510(%rbp,%rax,4)
07
je     1262 <main+0x142>
movslq -0xc(%rbp),%rax
cmpl   $0xd,-0xc3510(%rbp,%rax,4)
0d
je     1262 <main+0x142>
movslq -0xc(%rbp),%rax
cmpl   $0x11,-0xc3510(%rbp,%rax,4)
11
je     1262 <main+0x142>
movslq -0xc(%rbp),%rax
cmpl   $0x13,-0xc3510(%rbp,%rax,4)
13
je     1262 <main+0x142>
movslq -0xc(%rbp),%rax
cmpl   $0x1f,-0xc3510(%rbp,%rax,4)
1f
jne    1273 <main+0x153>
lea    0xd9d(%rip),%rdi
call   1030 <printf@plt>
jmp    127f <main+0x15f>
lea    0xd91(%rip),%rdi
call   1030 <printf@plt>
jmp    1284 <main+0x164>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    11c6 <main+0xa6>
xor    %eax,%eax
add    $0xc3520,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xc3518,%rsp
lea    0xec8(%rip),%rdi
xor    %r13d,%r13d
lea    0x8(%rsp),%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
cmpl   $0x2,0x8(%rsp)
jl     11a0 <main+0x80>
lea    0x10(%rsp),%rbx
lea    0xea6(%rip),%r14
lea    0xea2(%rip),%r15
lea    0xf(%rsp),%r12
xor    %r13d,%r13d
nopl   0x0(%rax)
mov    %r14,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
mov    %r15,%rdi
mov    %r12,%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
add    $0x1,%r13
movslq 0x8(%rsp),%rax
add    $0xffffffffffffffff,%rax
add    $0x4,%rbx
cmp    %rax,%r13
jl     1170 <main+0x50>
lea    (%rsp,%r13,4),%rsi
add    $0x10,%rsi
lea    0xe51(%rip),%rdi
xor    %eax,%eax
call   1040 <scanf@plt>
cmpl   $0x0,0x8(%rsp)
jle    1206 <main+0xe6>
xor    %ebx,%ebx
lea    0xe43(%rip),%r14
lea    0xe39(%rip),%r15
mov    $0x800a20ac,%ebp
jmp    11f3 <main+0xd3>
mov    %r15,%rdi
nopw   0x0(%rax,%rax,1)
call   1030 <puts@plt>
add    $0x1,%rbx
movslq 0x8(%rsp),%rax
cmp    %rax,%rbx
jge    1206 <main+0xe6>
mov    0x10(%rsp,%rbx,4),%eax
cmp    $0x1f,%eax
ja     11d4 <main+0xb4>
bt     %eax,%ebp
mov    %r14,%rdi
jb     11e0 <main+0xc0>
jmp    11d4 <main+0xb4>
xor    %eax,%eax
add    $0xc3518,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [3 x i8] c"%c\00"
@.str.2 = [5 x i8] c"Yes\0A\00"
@.str.3 = [4 x i8] c"No\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca [200000 x i32]
%5 = alloca i8
store i32 0, i32* %1
%6 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
store i32 0, i32* %3
br label %7
7: ; preds = %18, %0
%8 = load i32, i32* %3
%9 = load i32, i32* %2
%10 = sub nsw i32 %9, 1
%11 = icmp slt i32 %8, %10
br i1 %11, label %12, label %21
12: ; preds = %7
%13 = load i32, i32* %3
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %14
%16 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %15)
%17 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* %5)
br label %18
18: ; preds = %12
%19 = load i32, i32* %3
%20 = add nsw i32 %19, 1
store i32 %20, i32* %3
br label %7
21: ; preds = %7
%22 = load i32, i32* %3
%23 = sext i32 %22 to i64
%24 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %23
%25 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %24)
store i32 0, i32* %3
br label %26
26: ; preds = %83, %21
%27 = load i32, i32* %3
%28 = load i32, i32* %2
%29 = icmp slt i32 %27, %28
br i1 %29, label %30, label %86
30: ; preds = %26
%31 = load i32, i32* %3
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %32
%34 = load i32, i32* %33
%35 = icmp eq i32 %34, 2
br i1 %35, label %78, label %36
36: ; preds = %30
%37 = load i32, i32* %3
%38 = sext i32 %37 to i64
%39 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %38
%40 = load i32, i32* %39
%41 = icmp eq i32 %40, 3
br i1 %41, label %78, label %42
42: ; preds = %36
%43 = load i32, i32* %3
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %44
%46 = load i32, i32* %45
%47 = icmp eq i32 %46, 5
br i1 %47, label %78, label %48
48: ; preds = %42
%49 = load i32, i32* %3
%50 = sext i32 %49 to i64
%51 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %50
%52 = load i32, i32* %51
%53 = icmp eq i32 %52, 7
br i1 %53, label %78, label %54
54: ; preds = %48
%55 = load i32, i32* %3
%56 = sext i32 %55 to i64
%57 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %56
%58 = load i32, i32* %57
%59 = icmp eq i32 %58, 13
br i1 %59, label %78, label %60
60: ; preds = %54
%61 = load i32, i32* %3
%62 = sext i32 %61 to i64
%63 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %62
%64 = load i32, i32* %63
%65 = icmp eq i32 %64, 17
br i1 %65, label %78, label %66
66: ; preds = %60
%67 = load i32, i32* %3
%68 = sext i32 %67 to i64
%69 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %68
%70 = load i32, i32* %69
%71 = icmp eq i32 %70, 19
br i1 %71, label %78, label %72
72: ; preds = %66
%73 = load i32, i32* %3
%74 = sext i32 %73 to i64
%75 = getelementptr inbounds [200000 x i32], [200000 x i32]* %4, i64 0, i64 %74
%76 = load i32, i32* %75
%77 = icmp eq i32 %76, 31
br i1 %77, label %78, label %80
78: ; preds = %72, %66, %60, %54, %48, %42, %36, %30
%79 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
br label %82
80: ; preds = %72
%81 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.3, i64 0, i64 0))
br label %82
82: ; preds = %80, %78
br label %83
83: ; preds = %82
%84 = load i32, i32* %3
%85 = add nsw i32 %84, 1
store i32 %85, i32* %3
br label %26
86: ; preds = %26
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [3 x i8] c"%c\00"
@str = [3 x i8] c"No\00"
@str.4 = [4 x i8] c"Yes\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [200000 x i32]
%3 = alloca i8
%4 = bitcast i32* %1 to i8*
%5 = bitcast [200000 x i32]* %2 to i8*
%6 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%7 = load i32, i32* %1
%8 = icmp sgt i32 %7, 1
br i1 %8, label %9, label %21
9: ; preds = %0, %9
%10 = phi i64 [ %14, %9 ], [ 0, %0 ]
%11 = getelementptr inbounds [200000 x i32], [200000 x i32]* %2, i64 0, i64 %10
%12 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %11)
%13 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* %3)
%14 = add nuw nsw i64 %10, 1
%15 = load i32, i32* %1
%16 = add nsw i32 %15, -1
%17 = sext i32 %16 to i64
%18 = icmp slt i64 %14, %17
br i1 %18, label %9, label %19
19: ; preds = %9
%20 = and i64 %14, 4294967295
br label %21
21: ; preds = %19, %0
%22 = phi i64 [ 0, %0 ], [ %20, %19 ]
%23 = getelementptr inbounds [200000 x i32], [200000 x i32]* %2, i64 0, i64 %22
%24 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %23)
%25 = load i32, i32* %1
%26 = icmp sgt i32 %25, 0
br i1 %26, label %27, label %39
27: ; preds = %21, %32
%28 = phi i64 [ %35, %32 ], [ 0, %21 ]
%29 = getelementptr inbounds [200000 x i32], [200000 x i32]* %2, i64 0, i64 %28
%30 = load i32, i32* %29
switch i32 %30, label %31 [
i32 2, label %32
i32 3, label %32
i32 5, label %32
i32 7, label %32
i32 13, label %32
i32 17, label %32
i32 19, label %32
i32 31, label %32
]
31: ; preds = %27
br label %32
32: ; preds = %27, %27, %27, %27, %27, %27, %27, %27, %31
%33 = phi i8* [ getelementptr inbounds ([3 x i8], [3 x i8]* @str, i64 0, i64 0), %31 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.4, i64 0, i64 0), %27 ]
%34 = call i32 @puts(i8* dereferenceable(1) %33)
%35 = add nuw nsw i64 %28, 1
%36 = load i32, i32* %1
%37 = sext i32 %36 to i64
%38 = icmp slt i64 %35, %37
br i1 %38, label %27, label %39
39: ; preds = %32, %21
ret i32 0
}