#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 check_prime(int);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ scanf(char *, int *);
int main() {
  int i;
  int N;
  int p = 1;
  scanf("%d", &N);
  for (i = 2; i < N; i++) {
    int q = check_prime(i) + check_prime(N - i);
    if (q == 0) {
      printf("Yes");
      return 0;
    }
  }
  printf("No");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x1,-0x10(%rbp)
lea    0xeb3(%rip),%rdi
lea    -0xc(%rbp),%rsi
call   1050 <scanf@plt>
movl   $0x2,-0x8(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    11be <main+0x8e>
mov    -0x8(%rbp),%edi
call   1030 <check_prime@plt>
mov    %eax,-0x18(%rbp)
mov    -0xc(%rbp),%edi
sub    -0x8(%rbp),%edi
call   1030 <check_prime@plt>
mov    %eax,%ecx
mov    -0x18(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jne    11ab <main+0x7b>
lea    0xe69(%rip),%rdi
call   1040 <printf@plt>
movl   $0x0,-0x4(%rbp)
jmp    11d1 <main+0xa1>
jmp    11b0 <main+0x80>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    115d <main+0x2d>
lea    0xe42(%rip),%rdi
call   1040 <printf@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x10,%rsp
lea    0xebd(%rip),%rdi
lea    0xc(%rsp),%rsi
call   1050 <scanf@plt>
lea    0xeb3(%rip),%r14
cmpl   $0x3,0xc(%rsp)
jl     119b <main+0x6b>
mov    $0x2,%ebp
mov    $0xfffffffe,%ebx
lea    0xe97(%rip),%r15
nopl   0x0(%rax)
mov    %ebp,%edi
call   1030 <check_prime@plt>
mov    %eax,%r12d
mov    0xc(%rsp),%edi
add    %ebx,%edi
call   1030 <check_prime@plt>
add    %r12d,%eax
je     1198 <main+0x68>
add    $0x1,%ebp
add    $0xffffffff,%ebx
cmp    0xc(%rsp),%ebp
jl     1170 <main+0x40>
jmp    119b <main+0x6b>
mov    %r15,%r14
mov    %r14,%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"Yes\00"
@.str.2 = [3 x i8] c"No\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 0, i32* %1
store i32 1, i32* %4
%6 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %3)
store i32 2, i32* %2
br label %7
7: ; preds = %24, %0
%8 = load i32, i32* %2
%9 = load i32, i32* %3
%10 = icmp slt i32 %8, %9
br i1 %10, label %11, label %27
11: ; preds = %7
%12 = load i32, i32* %2
%13 = call i32 @check_prime(i32 %12)
%14 = load i32, i32* %3
%15 = load i32, i32* %2
%16 = sub nsw i32 %14, %15
%17 = call i32 @check_prime(i32 %16)
%18 = add nsw i32 %13, %17
store i32 %18, i32* %5
%19 = load i32, i32* %5
%20 = icmp eq i32 %19, 0
br i1 %20, label %21, label %23
21: ; preds = %11
%22 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
store i32 0, i32* %1
br label %29
23: ; preds = %11
br label %24
24: ; preds = %23
%25 = load i32, i32* %2
%26 = add nsw i32 %25, 1
store i32 %26, i32* %2
br label %7
27: ; preds = %7
%28 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
store i32 0, i32* %1
br label %29
29: ; preds = %27, %21
%30 = load i32, i32* %1
ret i32 %30
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"Yes\00"
@.str.2 = [3 x i8] c"No\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%4 = load i32, i32* %1
%5 = icmp sgt i32 %4, 2
br i1 %5, label %9, label %18
6: ; preds = %9
%7 = load i32, i32* %1
%8 = icmp slt i32 %17, %7
br i1 %8, label %9, label %18
9: ; preds = %0, %6
%10 = phi i32 [ %17, %6 ], [ 2, %0 ]
%11 = call i32 @check_prime(i32 %10)
%12 = load i32, i32* %1
%13 = sub nsw i32 %12, %10
%14 = call i32 @check_prime(i32 %13)
%15 = sub i32 0, %14
%16 = icmp eq i32 %11, %15
%17 = add nuw nsw i32 %10, 1
br i1 %16, label %18, label %6
18: ; preds = %6, %9, %0
%19 = phi i8* [ getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), %0 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), %9 ], [ getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), %6 ]
%20 = call i32 @printf(i8* dereferenceable(1) %19)
ret i32 0
}