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


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeba(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1050 <scanf@plt>
movl   $0x2,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x10(%rbp)
mov    -0x8(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x10(%rbp),%eax
cmp    %ecx,%eax
jg     11cb <main+0x9b>
mov    -0xc(%rbp),%edi
call   1030 <check_prime@plt>
cmp    $0x0,%rax
je     11b8 <main+0x88>
mov    -0x8(%rbp),%edi
sub    -0xc(%rbp),%edi
call   1030 <check_prime@plt>
cmp    $0x0,%rax
je     11b3 <main+0x83>
lea    0xe61(%rip),%rdi
call   1040 <printf@plt>
movl   $0x0,-0x4(%rbp)
jmp    11de <main+0xae>
jmp    11b8 <main+0x88>
jmp    11bd <main+0x8d>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1156 <main+0x26>
lea    0xe36(%rip),%rdi
call   1040 <printf@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
lea    0xec2(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1050 <scanf@plt>
lea    0xeb4(%rip),%r15
cmpl   $0x4,0x4(%rsp)
jl     11a6 <main+0x76>
mov    $0x1,%ebp
mov    $0xfffffffe,%ebx
lea    0xe9f(%rip),%r14
jmp    1184 <main+0x54>
nopl   0x0(%rax)
mov    0x4(%rsp),%eax
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
add    $0xffffffff,%ebx
cmp    %ecx,%ebp
jge    11a6 <main+0x76>
add    $0x1,%ebp
mov    %ebp,%edi
call   1030 <check_prime@plt>
test   %rax,%rax
je     1170 <main+0x40>
mov    0x4(%rsp),%edi
add    %ebx,%edi
call   1030 <check_prime@plt>
test   %rax,%rax
je     1170 <main+0x40>
mov    %r14,%r15
mov    %r15,%rdi
call   1040 <puts@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

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

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@str = [3 x i8] c"No\00"
@str.3 = [4 x i8] c"Yes\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 slt i32 %4, 4
br i1 %5, label %20, label %6
6: ; preds = %0, %15
%7 = phi i32 [ %16, %15 ], [ 2, %0 ]
%8 = call i64 @check_prime(i32 %7)
%9 = icmp eq i64 %8, 0
br i1 %9, label %15, label %10
10: ; preds = %6
%11 = load i32, i32* %1
%12 = sub nsw i32 %11, %7
%13 = call i64 @check_prime(i32 %12)
%14 = icmp eq i64 %13, 0
br i1 %14, label %15, label %20
15: ; preds = %6, %10
%16 = add nuw nsw i32 %7, 1
%17 = load i32, i32* %1
%18 = sdiv i32 %17, 2
%19 = icmp slt i32 %7, %18
br i1 %19, label %6, label %20
20: ; preds = %15, %10, %0
%21 = phi i8* [ getelementptr inbounds ([3 x i8], [3 x i8]* @str, i64 0, i64 0), %0 ], [ getelementptr inbounds ([4 x i8], [4 x i8]* @str.3, i64 0, i64 0), %10 ], [ getelementptr inbounds ([3 x i8], [3 x i8]* @str, i64 0, i64 0), %15 ]
%22 = call i32 @puts(i8* dereferenceable(1) %21)
ret i32 0
}