#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 *, long long *);
int main(void) {
  int i;
  long long int a;
  scanf("%lld", &a);
  if (a % 2) {
    if (a % 3 == 0) {
      printf("yes");
    } else if ((a - 7) % 6 == 0) {
      printf("yes");
    } else {
      printf("no");
    }
  } else if (a % 3 == 0) {
    printf("yes");
  } else {
    printf("no");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x10(%rbp),%rsi
call   1040 <scanf@plt>
mov    -0x10(%rbp),%rax
mov    $0x2,%ecx
cqto
idiv   %rcx
cmp    $0x0,%rdx
je     11c3 <main+0xa3>
mov    -0x10(%rbp),%rax
mov    $0x3,%ecx
cqto
idiv   %rcx
cmp    $0x0,%rdx
jne    1180 <main+0x60>
lea    0xe8f(%rip),%rdi
call   1030 <printf@plt>
jmp    11be <main+0x9e>
mov    -0x10(%rbp),%rax
sub    $0x7,%rax
mov    $0x6,%ecx
cqto
idiv   %rcx
cmp    $0x0,%rdx
jne    11ad <main+0x8d>
lea    0xe62(%rip),%rdi
call   1030 <printf@plt>
jmp    11b9 <main+0x99>
lea    0xe55(%rip),%rdi
call   1030 <printf@plt>
jmp    11be <main+0x9e>
jmp    11fd <main+0xdd>
mov    -0x10(%rbp),%rax
mov    $0x3,%ecx
cqto
idiv   %rcx
cmp    $0x0,%rdx
jne    11ec <main+0xcc>
lea    0xe23(%rip),%rdi
call   1030 <printf@plt>
jmp    11f8 <main+0xd8>
lea    0xe16(%rip),%rdi
call   1030 <printf@plt>
jmp    11fd <main+0xdd>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rdi
mov    %rsp,%rsi
call   1040 <scanf@plt>
mov    (%rsp),%rcx
movabs $0x5555555555555556,%rdx
55 55 55
mov    %rcx,%rax
imul   %rdx
mov    %rdx,%rax
shr    $0x3f,%rax
add    %rdx,%rax
lea    (%rax,%rax,2),%rdx
mov    %rcx,%rax
sub    %rdx,%rax
test   $0x1,%cl
jne    1174 <main+0x54>
test   %rax,%rax
lea    0xe9e(%rip),%rax
lea    0xe9b(%rip),%rdi
cmove  %rax,%rdi
jmp    11bf <main+0x9f>
test   %rax,%rax
je     11b8 <main+0x98>
movabs $0xaaaaaaaaaaaaaaab,%rax
aa aa aa
imul   %rax,%rcx
movabs $0x7ffffffffffffffd,%rax
ff ff 7f
add    %rcx,%rax
ror    %rax
movabs $0x2aaaaaaaaaaaaaab,%rcx
aa aa 2a
cmp    %rcx,%rax
lea    0xe5a(%rip),%rax
lea    0xe57(%rip),%rdi
cmovb  %rax,%rdi
jmp    11bf <main+0x9f>
lea    0xe46(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [5 x i8] c"%lld\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 i64
store i32 0, i32* %1
%4 = call i32 @scanf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i64* %3)
%5 = load i64, i64* %3
%6 = srem i64 %5, 2
%7 = icmp ne i64 %6, 0
br i1 %7, label %8, label %25
8: ; preds = %0
%9 = load i64, i64* %3
%10 = srem i64 %9, 3
%11 = icmp eq i64 %10, 0
br i1 %11, label %12, label %14
12: ; preds = %8
%13 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
br label %24
14: ; preds = %8
%15 = load i64, i64* %3
%16 = sub nsw i64 %15, 7
%17 = srem i64 %16, 6
%18 = icmp eq i64 %17, 0
br i1 %18, label %19, label %21
19: ; preds = %14
%20 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
br label %23
21: ; preds = %14
%22 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
br label %23
23: ; preds = %21, %19
br label %24
24: ; preds = %23, %12
br label %34
25: ; preds = %0
%26 = load i64, i64* %3
%27 = srem i64 %26, 3
%28 = icmp eq i64 %27, 0
br i1 %28, label %29, label %31
29: ; preds = %25
%30 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
br label %33
31: ; preds = %25
%32 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
br label %33
33: ; preds = %31, %29
br label %34
34: ; preds = %33, %24
ret i32 0
}

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