#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 */
typedef int /*<<< orphan*/ buff;
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ assert(int /*<<< orphan*/ *);
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
scalar_t__ fgets(char *, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char const *, char *);
int /*<<< orphan*/ memcmp(char *, char const *, int);
int /*<<< orphan*/ printf(char *, ...);
int strlen(char const *);
int main(const int argc, const char **argv) {
  const char *inbox_filename = "/home/phred/.thunderbird/ye4urkt7.default/"
                               "ImapMail/shared5.mainehost-1.net/INBOX";
  const char *inbox2_filename = "/home/olga/.thunderbird/3oz6ykst.default/"
                                "ImapMail/shared5.mainehost.net/INBOX";
  FILE *ifile = fopen(inbox_filename, "rb");
  char buff[200];
  const char *search_obj = (argc > 1 ? argv[1] : "");
  int state = 0;
  if (!ifile)
    ifile = fopen(inbox2_filename, "rb");
  assert(ifile);
  while (fgets(buff, sizeof(buff), ifile)) {
    if (!memcmp(buff, "Subject: 703 ARTSAT ", 20) ||
        !memcmp(buff, "Subject: G96 ARTSAT ", 20) ||
        !memcmp(buff, "Subject: I52 ARTSAT ", 20) ||
        !memcmp(buff, "Subject: V06 ARTSAT ", 20))
      if (!memcmp(buff + 20, search_obj, strlen(search_obj))) {
        printf("\n");
        state = 1;
      }
    if (state == 1)
      if (!memcmp(buff, "COD G96", 7) || !memcmp(buff, "COD 703", 7) ||
          !memcmp(buff, "COD I52", 7) || !memcmp(buff, "COD V06", 7))
        state = 2;
    if (state == 2 && !memcmp(buff, "From", 4))
      state = 0;
    if (state == 2)
      printf("%s", buff);
  }
  fclose(ifile);
  return (0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x120,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xe70(%rip),%rax
mov    %rax,-0x18(%rbp)
lea    0xeb6(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    -0x18(%rbp),%rdi
lea    0xef5(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,-0x28(%rbp)
cmpl   $0x1,-0x8(%rbp)
jle    11d1 <main+0x61>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rax
mov    %rax,-0x108(%rbp)
jmp    11e4 <main+0x74>
lea    0xf1f(%rip),%rax
mov    %rax,-0x108(%rbp)
jmp    11e4 <main+0x74>
mov    -0x108(%rbp),%rax
mov    %rax,-0xf8(%rbp)
movl   $0x0,-0xfc(%rbp)
cmpq   $0x0,-0x28(%rbp)
jne    121b <main+0xab>
mov    -0x20(%rbp),%rdi
lea    0xe8d(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,-0x28(%rbp)
mov    -0x28(%rbp),%rdi
call   1080 <assert@plt>
lea    -0xf0(%rbp),%rdi
mov    -0x28(%rbp),%rdx
mov    $0xc8,%esi
call   1070 <fgets@plt>
cmp    $0x0,%rax
je     142d <main+0x2bd>
lea    -0xf0(%rbp),%rdi
lea    0xe51(%rip),%rsi
mov    $0x14,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
je     12c7 <main+0x157>
lea    -0xf0(%rbp),%rdi
lea    0xe45(%rip),%rsi
mov    $0x14,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
je     12c7 <main+0x157>
lea    -0xf0(%rbp),%rdi
lea    0xe39(%rip),%rsi
mov    $0x14,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
je     12c7 <main+0x157>
lea    -0xf0(%rbp),%rdi
lea    0xe2d(%rip),%rsi
mov    $0x14,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
jne    132e <main+0x1be>
lea    -0xf0(%rbp),%rax
add    $0x14,%rax
mov    %rax,-0x118(%rbp)
mov    -0xf8(%rbp),%rax
mov    %rax,-0x110(%rbp)
mov    -0xf8(%rbp),%rdi
call   1040 <strlen@plt>
mov    -0x118(%rbp),%rdi
mov    -0x110(%rbp),%rsi
mov    %eax,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
jne    1329 <main+0x1b9>
lea    0xdde(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
movl   $0x1,-0xfc(%rbp)
jmp    132e <main+0x1be>
cmpl   $0x1,-0xfc(%rbp)
jne    13ce <main+0x25e>
lea    -0xf0(%rbp),%rdi
lea    0xdaf(%rip),%rsi
mov    $0x7,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
je     13bf <main+0x24f>
lea    -0xf0(%rbp),%rdi
lea    0xd96(%rip),%rsi
mov    $0x7,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
je     13bf <main+0x24f>
lea    -0xf0(%rbp),%rdi
lea    0xd7d(%rip),%rsi
mov    $0x7,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
je     13bf <main+0x24f>
lea    -0xf0(%rbp),%rdi
lea    0xd64(%rip),%rsi
mov    $0x7,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
jne    13c9 <main+0x259>
movl   $0x2,-0xfc(%rbp)
jmp    13ce <main+0x25e>
cmpl   $0x2,-0xfc(%rbp)
jne    1406 <main+0x296>
lea    -0xf0(%rbp),%rdi
lea    0xd2f(%rip),%rsi
mov    $0x4,%edx
call   1060 <memcmp@plt>
cmp    $0x0,%eax
jne    1406 <main+0x296>
movl   $0x0,-0xfc(%rbp)
cmpl   $0x2,-0xfc(%rbp)
jne    1428 <main+0x2b8>
lea    -0xf0(%rbp),%rsi
lea    0xcfc(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
jmp    1224 <main+0xb4>
mov    -0x28(%rbp),%rdi
call   1030 <fclose@plt>
xor    %eax,%eax
add    $0x120,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xc8,%rsp
mov    %rsi,%rbx
mov    %edi,%ebp
lea    0xe63(%rip),%rdi
lea    0xefb(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,%r14
cmp    $0x2,%ebp
jl     11bc <main+0x3c>
mov    0x8(%rbx),%r13
test   %r14,%r14
jne    11de <main+0x5e>
jmp    11c8 <main+0x48>
lea    0xf1d(%rip),%r13
test   %r14,%r14
jne    11de <main+0x5e>
lea    0xe82(%rip),%rdi
lea    0xec9(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,%r14
mov    %r14,%rdi
call   1090 <assert@plt>
mov    %rsp,%rdi
mov    $0xc8,%esi
mov    %r14,%rdx
call   1080 <fgets@plt>
test   %rax,%rax
je     1397 <main+0x217>
lea    0x14(%rsp),%r15
lea    0xe97(%rip),%r12
mov    %rsp,%rbx
xor    %ebp,%ebp
jmp    126b <main+0xeb>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    %rbx,%rdi
lea    0xeec(%rip),%rsi
mov    $0x4,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     1390 <main+0x210>
lea    0xed8(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
mov    $0x2,%ebp
mov    %rbx,%rdi
mov    $0xc8,%esi
mov    %r14,%rdx
call   1080 <fgets@plt>
test   %rax,%rax
je     1397 <main+0x217>
mov    %rbx,%rdi
mov    %r12,%rsi
mov    $0x14,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     12d0 <main+0x150>
mov    %rbx,%rdi
lea    0xe2e(%rip),%rsi
mov    $0x14,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     12d0 <main+0x150>
mov    %rbx,%rdi
lea    0xe2b(%rip),%rsi
mov    $0x14,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     12d0 <main+0x150>
mov    %rbx,%rdi
lea    0xe28(%rip),%rsi
mov    $0x14,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
jne    12e9 <main+0x169>
nopw   0x0(%rax,%rax,1)
mov    %r13,%rdi
call   1050 <strlen@plt>
mov    %r15,%rdi
mov    %r13,%rsi
mov    %eax,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     1300 <main+0x180>
cmp    $0x2,%ebp
je     1220 <main+0xa0>
cmp    $0x1,%ebp
je     130a <main+0x18a>
jmp    1252 <main+0xd2>
nopl   0x0(%rax)
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rdi
lea    0xde2(%rip),%rsi
mov    $0x7,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     1220 <main+0xa0>
mov    %rbx,%rdi
lea    0xdce(%rip),%rsi
mov    $0x7,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     1220 <main+0xa0>
mov    %rbx,%rdi
lea    0xdba(%rip),%rsi
mov    $0x7,%edx
call   1070 <memcmp@plt>
test   %eax,%eax
je     1220 <main+0xa0>
mov    %rbx,%rdi
lea    0xda6(%rip),%rsi
mov    $0x7,%edx
call   1070 <memcmp@plt>
mov    $0x1,%ebp
test   %eax,%eax
jne    1252 <main+0xd2>
jmp    1220 <main+0xa0>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
xor    %ebp,%ebp
jmp    1252 <main+0xd2>
mov    %r14,%rdi
call   1040 <fclose@plt>
xor    %eax,%eax
add    $0xc8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [81 x i8] c"/home/phred/.thunderbird/ye4urkt7.default/ImapMail/shared5.mainehost-1.net/INBOX\00"
@.str.1 = [78 x i8] c"/home/olga/.thunderbird/3oz6ykst.default/ImapMail/shared5.mainehost.net/INBOX\00"
@.str.2 = [3 x i8] c"rb\00"
@.str.3 = [1 x i8] zeroinitializer
@.str.4 = [21 x i8] c"Subject: 703 ARTSAT \00"
@.str.5 = [21 x i8] c"Subject: G96 ARTSAT \00"
@.str.6 = [21 x i8] c"Subject: I52 ARTSAT \00"
@.str.7 = [21 x i8] c"Subject: V06 ARTSAT \00"
@.str.8 = [2 x i8] c"\0A\00"
@.str.9 = [8 x i8] c"COD G96\00"
@.str.10 = [8 x i8] c"COD 703\00"
@.str.11 = [8 x i8] c"COD I52\00"
@.str.12 = [8 x i8] c"COD V06\00"
@.str.13 = [5 x i8] c"From\00"
@.str.14 = [3 x i8] c"%s\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i32*
%9 = alloca [200 x i8]
%10 = alloca i8*
%11 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i8* getelementptr inbounds ([81 x i8], [81 x i8]* @.str, i64 0, i64 0), i8** %6
store i8* getelementptr inbounds ([78 x i8], [78 x i8]* @.str.1, i64 0, i64 0), i8** %7
%12 = load i8*, i8** %6
%13 = call i32* @fopen(i8* %12, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
store i32* %13, i32** %8
%14 = load i32, i32* %4
%15 = icmp sgt i32 %14, 1
br i1 %15, label %16, label %20
16: ; preds = %2
%17 = load i8**, i8*** %5
%18 = getelementptr inbounds i8*, i8** %17, i64 1
%19 = load i8*, i8** %18
br label %21
20: ; preds = %2
br label %21
21: ; preds = %20, %16
%22 = phi i8* [ %19, %16 ], [ getelementptr inbounds ([1 x i8], [1 x i8]* @.str.3, i64 0, i64 0), %20 ]
store i8* %22, i8** %10
store i32 0, i32* %11
%23 = load i32*, i32** %8
%24 = icmp ne i32* %23, null
br i1 %24, label %28, label %25
25: ; preds = %21
%26 = load i8*, i8** %7
%27 = call i32* @fopen(i8* %26, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
store i32* %27, i32** %8
br label %28
28: ; preds = %25, %21
%29 = load i32*, i32** %8
%30 = call i32 @assert(i32* %29)
br label %31
31: ; preds = %98, %28
%32 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%33 = load i32*, i32** %8
%34 = call i64 @fgets(i8* %32, i32 200, i32* %33)
%35 = icmp ne i64 %34, 0
br i1 %35, label %36, label %99
36: ; preds = %31
%37 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%38 = call i32 @memcmp(i8* %37, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.4, i64 0, i64 0), i32 20)
%39 = icmp ne i32 %38, 0
br i1 %39, label %40, label %52
40: ; preds = %36
%41 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%42 = call i32 @memcmp(i8* %41, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.5, i64 0, i64 0), i32 20)
%43 = icmp ne i32 %42, 0
br i1 %43, label %44, label %52
44: ; preds = %40
%45 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%46 = call i32 @memcmp(i8* %45, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.6, i64 0, i64 0), i32 20)
%47 = icmp ne i32 %46, 0
br i1 %47, label %48, label %52
48: ; preds = %44
%49 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%50 = call i32 @memcmp(i8* %49, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.7, i64 0, i64 0), i32 20)
%51 = icmp ne i32 %50, 0
br i1 %51, label %63, label %52
52: ; preds = %48, %44, %40, %36
%53 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%54 = getelementptr inbounds i8, i8* %53, i64 20
%55 = load i8*, i8** %10
%56 = load i8*, i8** %10
%57 = call i32 @strlen(i8* %56)
%58 = call i32 @memcmp(i8* %54, i8* %55, i32 %57)
%59 = icmp ne i32 %58, 0
br i1 %59, label %62, label %60
60: ; preds = %52
%61 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
store i32 1, i32* %11
br label %62
62: ; preds = %60, %52
br label %63
63: ; preds = %62, %48
%64 = load i32, i32* %11
%65 = icmp eq i32 %64, 1
br i1 %65, label %66, label %84
66: ; preds = %63
%67 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%68 = call i32 @memcmp(i8* %67, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.9, i64 0, i64 0), i32 7)
%69 = icmp ne i32 %68, 0
br i1 %69, label %70, label %82
70: ; preds = %66
%71 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%72 = call i32 @memcmp(i8* %71, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0), i32 7)
%73 = icmp ne i32 %72, 0
br i1 %73, label %74, label %82
74: ; preds = %70
%75 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%76 = call i32 @memcmp(i8* %75, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.11, i64 0, i64 0), i32 7)
%77 = icmp ne i32 %76, 0
br i1 %77, label %78, label %82
78: ; preds = %74
%79 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%80 = call i32 @memcmp(i8* %79, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.12, i64 0, i64 0), i32 7)
%81 = icmp ne i32 %80, 0
br i1 %81, label %83, label %82
82: ; preds = %78, %74, %70, %66
store i32 2, i32* %11
br label %83
83: ; preds = %82, %78
br label %84
84: ; preds = %83, %63
%85 = load i32, i32* %11
%86 = icmp eq i32 %85, 2
br i1 %86, label %87, label %92
87: ; preds = %84
%88 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%89 = call i32 @memcmp(i8* %88, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.13, i64 0, i64 0), i32 4)
%90 = icmp ne i32 %89, 0
br i1 %90, label %92, label %91
91: ; preds = %87
store i32 0, i32* %11
br label %92
92: ; preds = %91, %87, %84
%93 = load i32, i32* %11
%94 = icmp eq i32 %93, 2
br i1 %94, label %95, label %98
95: ; preds = %92
%96 = getelementptr inbounds [200 x i8], [200 x i8]* %9, i64 0, i64 0
%97 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.14, i64 0, i64 0), i8* %96)
br label %98
98: ; preds = %95, %92
br label %31
99: ; preds = %31
%100 = load i32*, i32** %8
%101 = call i32 @fclose(i32* %100)
ret i32 0
}

LLVM IR (-O2):
@.str = [81 x i8] c"/home/phred/.thunderbird/ye4urkt7.default/ImapMail/shared5.mainehost-1.net/INBOX\00"
@.str.1 = [78 x i8] c"/home/olga/.thunderbird/3oz6ykst.default/ImapMail/shared5.mainehost.net/INBOX\00"
@.str.2 = [3 x i8] c"rb\00"
@.str.3 = [1 x i8] zeroinitializer
@.str.4 = [21 x i8] c"Subject: 703 ARTSAT \00"
@.str.5 = [21 x i8] c"Subject: G96 ARTSAT \00"
@.str.6 = [21 x i8] c"Subject: I52 ARTSAT \00"
@.str.7 = [21 x i8] c"Subject: V06 ARTSAT \00"
@.str.9 = [8 x i8] c"COD G96\00"
@.str.10 = [8 x i8] c"COD 703\00"
@.str.11 = [8 x i8] c"COD I52\00"
@.str.12 = [8 x i8] c"COD V06\00"
@.str.13 = [5 x i8] c"From\00"
@.str.14 = [3 x i8] c"%s\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = alloca [200 x i8]
%4 = tail call i32* @fopen(i8* getelementptr inbounds ([81 x i8], [81 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%5 = getelementptr inbounds [200 x i8], [200 x i8]* %3, i64 0, i64 0
%6 = icmp sgt i32 %0, 1
br i1 %6, label %7, label %10
7: ; preds = %2
%8 = getelementptr inbounds i8*, i8** %1, i64 1
%9 = load i8*, i8** %8
br label %10
10: ; preds = %2, %7
%11 = phi i8* [ %9, %7 ], [ getelementptr inbounds ([1 x i8], [1 x i8]* @.str.3, i64 0, i64 0), %2 ]
%12 = icmp eq i32* %4, null
br i1 %12, label %13, label %15
13: ; preds = %10
%14 = tail call i32* @fopen(i8* getelementptr inbounds ([78 x i8], [78 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 %15
15: ; preds = %13, %10
%16 = phi i32* [ %4, %10 ], [ %14, %13 ]
%17 = tail call i32 @assert(i32* %16)
%18 = call i64 @fgets(i8* %5, i32 200, i32* %16)
%19 = icmp eq i64 %18, 0
br i1 %19, label %63, label %20
20: ; preds = %15
%21 = getelementptr inbounds [200 x i8], [200 x i8]* %3, i64 0, i64 20
br label %22
22: ; preds = %20, %59
%23 = phi i32 [ 0, %20 ], [ %60, %59 ]
%24 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.4, i64 0, i64 0), i32 20)
%25 = icmp eq i32 %24, 0
br i1 %25, label %35, label %26
26: ; preds = %22
%27 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.5, i64 0, i64 0), i32 20)
%28 = icmp eq i32 %27, 0
br i1 %28, label %35, label %29
29: ; preds = %26
%30 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.6, i64 0, i64 0), i32 20)
%31 = icmp eq i32 %30, 0
br i1 %31, label %35, label %32
32: ; preds = %29
%33 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.7, i64 0, i64 0), i32 20)
%34 = icmp eq i32 %33, 0
br i1 %34, label %35, label %41
35: ; preds = %32, %29, %26, %22
%36 = call i32 @strlen(i8* %11)
%37 = call i32 @memcmp(i8* %21, i8* %11, i32 %36)
%38 = icmp eq i32 %37, 0
br i1 %38, label %39, label %41
39: ; preds = %35
%40 = call i32 @putchar(i32 10)
br label %42
41: ; preds = %35, %32
switch i32 %23, label %59 [
i32 1, label %42
i32 2, label %54
]
42: ; preds = %41, %39
%43 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.9, i64 0, i64 0), i32 7)
%44 = icmp eq i32 %43, 0
br i1 %44, label %54, label %45
45: ; preds = %42
%46 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.10, i64 0, i64 0), i32 7)
%47 = icmp eq i32 %46, 0
br i1 %47, label %54, label %48
48: ; preds = %45
%49 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.11, i64 0, i64 0), i32 7)
%50 = icmp eq i32 %49, 0
br i1 %50, label %54, label %51
51: ; preds = %48
%52 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.12, i64 0, i64 0), i32 7)
%53 = icmp eq i32 %52, 0
br i1 %53, label %54, label %59
54: ; preds = %41, %51, %48, %45, %42
%55 = call i32 @memcmp(i8* %5, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.13, i64 0, i64 0), i32 4)
%56 = icmp eq i32 %55, 0
br i1 %56, label %59, label %57
57: ; preds = %54
%58 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.14, i64 0, i64 0), i8* %5)
br label %59
59: ; preds = %41, %54, %51, %57
%60 = phi i32 [ 2, %57 ], [ 1, %51 ], [ 0, %54 ], [ %23, %41 ]
%61 = call i64 @fgets(i8* %5, i32 200, i32* %16)
%62 = icmp eq i64 %61, 0
br i1 %62, label %63, label %22
63: ; preds = %59, %15
%64 = call i32 @fclose(i32* %16)
ret i32 0
}