#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 input();
scalar_t__ skip_comment();
int skip_to_next_directive() {
  int state = 0;
  int c;
  do {
    c = input();
    if (c == 0) {
      break;
    }
    if (c == '\n') {
      state = 0;
      c = input();
    }
    if (c == '/') {
      if ((c = input()) == '*') {
        if (skip_comment() == 0) {
          return 0;
        }
        c = input();
      }
    }
    if (c == '\\') {
      if ((c = input()) == '\r') {
        c = input();
      }
      if (c == '\n') {
        c = input();
      }
    }
    while (c == ' ' || c == '\t') {
      c = input();
    }
    if (state == 0 && c == '#') {
      break;
    }
  } while (c != 0);
  return c;
}


x86 assembly (clang, -O0):
<skip_to_next_directive>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x8(%rbp)
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
jne    1148 <skip_to_next_directive+0x28>
jmp    1251 <skip_to_next_directive+0x131>
cmpl   $0xa,-0xc(%rbp)
jne    1163 <skip_to_next_directive+0x43>
movl   $0x0,-0x8(%rbp)
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
cmpl   $0x2f,-0xc(%rbp)
jne    11ac <skip_to_next_directive+0x8c>
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
cmp    $0x2a,%eax
jne    11a7 <skip_to_next_directive+0x87>
mov    $0x0,%al
call   1040 <skip_comment@plt>
cmp    $0x0,%rax
jne    119d <skip_to_next_directive+0x7d>
movl   $0x0,-0x4(%rbp)
jmp    1257 <skip_to_next_directive+0x137>
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
jmp    11ac <skip_to_next_directive+0x8c>
cmpl   $0x5c,-0xc(%rbp)
jne    11ec <skip_to_next_directive+0xcc>
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
cmp    $0xd,%eax
jne    11d3 <skip_to_next_directive+0xb3>
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
cmpl   $0xa,-0xc(%rbp)
jne    11e7 <skip_to_next_directive+0xc7>
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
jmp    11ec <skip_to_next_directive+0xcc>
jmp    11f1 <skip_to_next_directive+0xd1>
mov    $0x1,%al
cmpl   $0x20,-0xc(%rbp)
mov    %al,-0xd(%rbp)
je     120a <skip_to_next_directive+0xea>
cmpl   $0x9,-0xc(%rbp)
sete   %al
mov    %al,-0xd(%rbp)
mov    -0xd(%rbp),%al
test   $0x1,%al
jne    121a <skip_to_next_directive+0xfa>
jmp    1229 <skip_to_next_directive+0x109>
mov    $0x0,%al
call   1030 <input@plt>
mov    %eax,-0xc(%rbp)
jmp    11f1 <skip_to_next_directive+0xd1>
cmpl   $0x0,-0x8(%rbp)
jne    1242 <skip_to_next_directive+0x122>
cmpl   $0x23,-0xc(%rbp)
jne    1242 <skip_to_next_directive+0x122>
jmp    1251 <skip_to_next_directive+0x131>
jmp    1247 <skip_to_next_directive+0x127>
cmpl   $0x0,-0xc(%rbp)
jne    112f <skip_to_next_directive+0xf>
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<skip_to_next_directive>:
push   %r14
push   %rbx
push   %rax
lea    0xed5(%rip),%r14
nopl   0x0(%rax,%rax,1)
xor    %eax,%eax
call   1030 <input@plt>
cmp    $0xa,%eax
je     1150 <skip_to_next_directive+0x30>
mov    %eax,%ebx
test   %eax,%eax
je     11cd <skip_to_next_directive+0xad>
cmp    $0x2f,%ebx
je     115e <skip_to_next_directive+0x3e>
jmp    1183 <skip_to_next_directive+0x63>
nopl   (%rax)
xor    %eax,%eax
call   1030 <input@plt>
mov    %eax,%ebx
cmp    $0x2f,%ebx
jne    1183 <skip_to_next_directive+0x63>
xor    %eax,%eax
call   1030 <input@plt>
mov    %eax,%ebx
cmp    $0x2a,%eax
jne    1183 <skip_to_next_directive+0x63>
xor    %ebx,%ebx
xor    %eax,%eax
call   1040 <skip_comment@plt>
test   %rax,%rax
je     11cd <skip_to_next_directive+0xad>
xor    %eax,%eax
call   1030 <input@plt>
mov    %eax,%ebx
cmp    $0x5c,%ebx
jne    11b9 <skip_to_next_directive+0x99>
xor    %eax,%eax
call   1030 <input@plt>
mov    %eax,%ebx
cmp    $0xd,%eax
jne    119f <skip_to_next_directive+0x7f>
xor    %eax,%eax
call   1030 <input@plt>
mov    %eax,%ebx
cmp    $0xa,%ebx
jne    11b9 <skip_to_next_directive+0x99>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
xor    %eax,%eax
call   1030 <input@plt>
mov    %eax,%ebx
mov    %ebx,%eax
cmp    $0x23,%ebx
ja     1130 <skip_to_next_directive+0x10>
movslq (%r14,%rax,4),%rax
add    %r14,%rax
jmp    *%rax
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
define i32 @skip_to_next_directive() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %2
br label %4
4: ; preds = %60, %0
%5 = call i32 (...) @input()
store i32 %5, i32* %3
%6 = load i32, i32* %3
%7 = icmp eq i32 %6, 0
br i1 %7, label %8, label %9
8: ; preds = %4
br label %63
9: ; preds = %4
%10 = load i32, i32* %3
%11 = icmp eq i32 %10, 10
br i1 %11, label %12, label %14
12: ; preds = %9
store i32 0, i32* %2
%13 = call i32 (...) @input()
store i32 %13, i32* %3
br label %14
14: ; preds = %12, %9
%15 = load i32, i32* %3
%16 = icmp eq i32 %15, 47
br i1 %16, label %17, label %27
17: ; preds = %14
%18 = call i32 (...) @input()
store i32 %18, i32* %3
%19 = icmp eq i32 %18, 42
br i1 %19, label %20, label %26
20: ; preds = %17
%21 = call i64 (...) @skip_comment()
%22 = icmp eq i64 %21, 0
br i1 %22, label %23, label %24
23: ; preds = %20
store i32 0, i32* %1
br label %65
24: ; preds = %20
%25 = call i32 (...) @input()
store i32 %25, i32* %3
br label %26
26: ; preds = %24, %17
br label %27
27: ; preds = %26, %14
%28 = load i32, i32* %3
%29 = icmp eq i32 %28, 92
br i1 %29, label %30, label %41
30: ; preds = %27
%31 = call i32 (...) @input()
store i32 %31, i32* %3
%32 = icmp eq i32 %31, 13
br i1 %32, label %33, label %35
33: ; preds = %30
%34 = call i32 (...) @input()
store i32 %34, i32* %3
br label %35
35: ; preds = %33, %30
%36 = load i32, i32* %3
%37 = icmp eq i32 %36, 10
br i1 %37, label %38, label %40
38: ; preds = %35
%39 = call i32 (...) @input()
store i32 %39, i32* %3
br label %40
40: ; preds = %38, %35
br label %41
41: ; preds = %40, %27
br label %42
42: ; preds = %50, %41
%43 = load i32, i32* %3
%44 = icmp eq i32 %43, 32
br i1 %44, label %48, label %45
45: ; preds = %42
%46 = load i32, i32* %3
%47 = icmp eq i32 %46, 9
br label %48
48: ; preds = %45, %42
%49 = phi i1 [ true, %42 ], [ %47, %45 ]
br i1 %49, label %50, label %52
50: ; preds = %48
%51 = call i32 (...) @input()
store i32 %51, i32* %3
br label %42
52: ; preds = %48
%53 = load i32, i32* %2
%54 = icmp eq i32 %53, 0
br i1 %54, label %55, label %59
55: ; preds = %52
%56 = load i32, i32* %3
%57 = icmp eq i32 %56, 35
br i1 %57, label %58, label %59
58: ; preds = %55
br label %63
59: ; preds = %55, %52
br label %60
60: ; preds = %59
%61 = load i32, i32* %3
%62 = icmp ne i32 %61, 0
br i1 %62, label %4, label %63
63: ; preds = %60, %58, %8
%64 = load i32, i32* %3
store i32 %64, i32* %1
br label %65
65: ; preds = %63, %23
%66 = load i32, i32* %1
ret i32 %66
}

LLVM IR (-O2):
define i32 @skip_to_next_directive() {
br label %1
1: ; preds = %29, %0
%2 = tail call i32 (...) @input()
switch i32 %2, label %5 [
i32 0, label %31
i32 10, label %3
]
3: ; preds = %1
%4 = tail call i32 (...) @input()
br label %5
5: ; preds = %1, %3
%6 = phi i32 [ %4, %3 ], [ %2, %1 ]
%7 = icmp eq i32 %6, 47
br i1 %7, label %8, label %16
8: ; preds = %5
%9 = tail call i32 (...) @input()
%10 = icmp eq i32 %9, 42
br i1 %10, label %11, label %16
11: ; preds = %8
%12 = tail call i64 (...) @skip_comment()
%13 = icmp eq i64 %12, 0
br i1 %13, label %31, label %14
14: ; preds = %11
%15 = tail call i32 (...) @input()
br label %16
16: ; preds = %8, %14, %5
%17 = phi i32 [ %15, %14 ], [ %9, %8 ], [ %6, %5 ]
%18 = icmp eq i32 %17, 92
br i1 %18, label %19, label %29
19: ; preds = %16
%20 = tail call i32 (...) @input()
%21 = icmp eq i32 %20, 13
br i1 %21, label %22, label %24
22: ; preds = %19
%23 = tail call i32 (...) @input()
br label %24
24: ; preds = %22, %19
%25 = phi i32 [ %23, %22 ], [ %20, %19 ]
%26 = icmp eq i32 %25, 10
br i1 %26, label %27, label %29
27: ; preds = %24, %29, %29
%28 = tail call i32 (...) @input()
br label %29
29: ; preds = %27, %16, %24
%30 = phi i32 [ %25, %24 ], [ %17, %16 ], [ %28, %27 ]
switch i32 %30, label %1 [
i32 32, label %27
i32 9, label %27
i32 35, label %31
i32 0, label %31
]
31: ; preds = %1, %11, %29, %29
%32 = phi i32 [ %30, %29 ], [ %30, %29 ], [ 0, %11 ], [ %2, %1 ]
ret i32 %32
}