#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*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ feof(int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, ...);
int /*<<< orphan*/ fscanf(int /*<<< orphan*/ *, char *, int *);
int rand();
int /*<<< orphan*/ srand(int /*<<< orphan*/);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
int getNum() {
  int i;
  srand(time(NULL));
  int temp = (rand() % 56) + 1;
  int finalNum = 0;
  FILE *fp3;
  fp3 = fopen("previous.dat", "r");
  int readNums[57] = {0};
  int arrayTemp;
  while (!feof(fp3)) {
    fscanf(fp3, "%d", &arrayTemp);
    readNums[arrayTemp] = 1;
  }
  fclose(fp3);
  int nothingLeft = 1;
  for (i = 1; i < 57; ++i) {
    if (readNums[i] == 0) {
      nothingLeft = 0;
      break;
    }
  }
  if (nothingLeft == 1) {
    fp3 = fopen("previous.dat", "w");
    fprintf(fp3, "%s", "");
    fclose(fp3);
    for (i = 1; i < 57; ++i) {
      readNums[i] = 0;
    }
  }
  int isFinal = 1;
  while (finalNum != temp) {
    isFinal = 1;
    for (i = 1; i < 57; ++i) {
      if (readNums[temp] == 1) {
        isFinal = 0;
        temp = (rand() % 56) + 1;
        break;
      }
    }
    if (isFinal == 1) {
      finalNum = temp;
      readNums[finalNum] = 1;
    }
  }
  fp3 = fopen("previous.dat", "w");
  for (i = 1; i < 57; ++i) {
    if (readNums[i] == 1) {
      fprintf(fp3, "%d\n", i);
    }
  }
  fclose(fp3);
  return finalNum;
}


x86 assembly (clang, -O0):
<getNum>:
push   %rbp
mov    %rsp,%rbp
sub    $0x110,%rsp
xor    %eax,%eax
mov    %eax,%edi
call   1090 <time@plt>
mov    %eax,%edi
call   1060 <srand@plt>
mov    $0x0,%al
call   10b0 <rand@plt>
mov    $0x38,%ecx
cltd
idiv   %ecx
add    $0x1,%edx
mov    %edx,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
lea    0xe32(%rip),%rdi
lea    0xe38(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x18(%rbp)
lea    -0x100(%rbp),%rdi
xor    %esi,%esi
mov    $0xe4,%edx
call   1040 <memset@plt>
mov    -0x18(%rbp),%rdi
call   1080 <feof@plt>
cmp    $0x0,%eax
setne  %al
xor    $0xff,%al
test   $0x1,%al
jne    120f <getNum+0x7f>
jmp    123d <getNum+0xad>
mov    -0x18(%rbp),%rdi
lea    0xdf5(%rip),%rsi
lea    -0x104(%rbp),%rdx
call   1050 <fscanf@plt>
movslq -0x104(%rbp),%rax
movl   $0x1,-0x100(%rbp,%rax,4)
jmp    11f1 <getNum+0x61>
mov    -0x18(%rbp),%rdi
call   1030 <fclose@plt>
movl   $0x1,-0x108(%rbp)
movl   $0x1,-0x4(%rbp)
cmpl   $0x39,-0x4(%rbp)
jge    1295 <getNum+0x105>
movslq -0x4(%rbp),%rax
cmpl   $0x0,-0x100(%rbp,%rax,4)
jne    1282 <getNum+0xf2>
movl   $0x0,-0x108(%rbp)
jmp    1295 <getNum+0x105>
jmp    1287 <getNum+0xf7>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    1257 <getNum+0xc7>
cmpl   $0x1,-0x108(%rbp)
jne    130e <getNum+0x17e>
lea    0xd57(%rip),%rdi
lea    0xd62(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
lea    0xd50(%rip),%rsi
lea    0xd4f(%rip),%rdx
mov    $0x0,%al
call   1070 <fprintf@plt>
mov    -0x18(%rbp),%rdi
call   1030 <fclose@plt>
movl   $0x1,-0x4(%rbp)
cmpl   $0x39,-0x4(%rbp)
jge    1309 <getNum+0x179>
movslq -0x4(%rbp),%rax
movl   $0x0,-0x100(%rbp,%rax,4)
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    12e2 <getNum+0x152>
jmp    130e <getNum+0x17e>
movl   $0x1,-0x10c(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x8(%rbp),%eax
je     13af <getNum+0x21f>
movl   $0x1,-0x10c(%rbp)
movl   $0x1,-0x4(%rbp)
cmpl   $0x39,-0x4(%rbp)
jge    1388 <getNum+0x1f8>
movslq -0x8(%rbp),%rax
cmpl   $0x1,-0x100(%rbp,%rax,4)
01
jne    1375 <getNum+0x1e5>
movl   $0x0,-0x10c(%rbp)
mov    $0x0,%al
call   10b0 <rand@plt>
mov    $0x38,%ecx
cltd
idiv   %ecx
add    $0x1,%edx
mov    %edx,-0x8(%rbp)
jmp    1388 <getNum+0x1f8>
jmp    137a <getNum+0x1ea>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    1335 <getNum+0x1a5>
cmpl   $0x1,-0x10c(%rbp)
jne    13aa <getNum+0x21a>
mov    -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
movslq -0xc(%rbp),%rax
movl   $0x1,-0x100(%rbp,%rax,4)
jmp    1318 <getNum+0x188>
lea    0xc4a(%rip),%rdi
lea    0xc55(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x18(%rbp)
movl   $0x1,-0x4(%rbp)
cmpl   $0x39,-0x4(%rbp)
jge    1411 <getNum+0x281>
movslq -0x4(%rbp),%rax
cmpl   $0x1,-0x100(%rbp,%rax,4)
01
jne    13fe <getNum+0x26e>
mov    -0x18(%rbp),%rdi
mov    -0x4(%rbp),%edx
lea    0xc20(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
jmp    1403 <getNum+0x273>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    13cd <getNum+0x23d>
mov    -0x18(%rbp),%rdi
call   1030 <fclose@plt>
mov    -0xc(%rbp),%eax
add    $0x110,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getNum>:
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x100,%rsp
xor    %edi,%edi
call   1080 <time@plt>
mov    %eax,%edi
call   1050 <srand@plt>
xor    %eax,%eax
call   10a0 <rand@plt>
movslq %eax,%r12
imul   $0xffffffff92492493,%r12,%rax
shr    $0x20,%rax
add    %r12d,%eax
mov    %eax,%ecx
shr    $0x1f,%ecx
sar    $0x5,%eax
add    %ecx,%eax
imul   $0x38,%eax,%r13d
neg    %r13d
lea    0xe32(%rip),%rdi
lea    0xe38(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,%r14
xorps  %xmm0,%xmm0
movaps %xmm0,0xe0(%rsp)
movaps %xmm0,0xd0(%rsp)
movaps %xmm0,0xc0(%rsp)
movaps %xmm0,0xb0(%rsp)
movaps %xmm0,0xa0(%rsp)
movaps %xmm0,0x90(%rsp)
movaps %xmm0,0x80(%rsp)
movaps %xmm0,0x70(%rsp)
movaps %xmm0,0x60(%rsp)
movaps %xmm0,0x50(%rsp)
movaps %xmm0,0x40(%rsp)
movaps %xmm0,0x30(%rsp)
movaps %xmm0,0x20(%rsp)
movaps %xmm0,0x10(%rsp)
movl   $0x0,0xf0(%rsp)
mov    %rax,%rdi
call   1070 <feof@plt>
test   %eax,%eax
jne    1287 <getNum+0x107>
lea    0xdb6(%rip),%r15
lea    0xc(%rsp),%rbx
xchg   %ax,%ax
mov    %r14,%rdi
mov    %r15,%rsi
mov    %rbx,%rdx
call   1040 <fscanf@plt>
movslq 0xc(%rsp),%rax
movl   $0x1,0x10(%rsp,%rax,4)
mov    %r14,%rdi
call   1070 <feof@plt>
test   %eax,%eax
je     1260 <getNum+0xe0>
lea    (%r12,%r13,1),%r15d
add    $0x1,%r15d
mov    %r14,%rdi
call   1030 <fclose@plt>
mov    $0x4,%eax
nopl   0x0(%rax)
cmpl   $0x0,0x4(%rsp,%rax,4)
je     134f <getNum+0x1cf>
cmpl   $0x0,0x8(%rsp,%rax,4)
je     134f <getNum+0x1cf>
cmpl   $0x0,0xc(%rsp,%rax,4)
je     134f <getNum+0x1cf>
cmpl   $0x0,0x10(%rsp,%rax,4)
je     134f <getNum+0x1cf>
add    $0x4,%rax
cmp    $0x3c,%rax
jne    12a0 <getNum+0x120>
lea    0xd23(%rip),%rdi
lea    0xd2e(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,%rdi
call   1030 <fclose@plt>
xorps  %xmm0,%xmm0
movups %xmm0,0x14(%rsp)
movups %xmm0,0x24(%rsp)
movups %xmm0,0x34(%rsp)
movups %xmm0,0x44(%rsp)
movups %xmm0,0x54(%rsp)
movups %xmm0,0x64(%rsp)
movups %xmm0,0x74(%rsp)
movups %xmm0,0x84(%rsp)
movups %xmm0,0x94(%rsp)
movups %xmm0,0xa4(%rsp)
movups %xmm0,0xb4(%rsp)
movups %xmm0,0xc4(%rsp)
movups %xmm0,0xd4(%rsp)
movups %xmm0,0xe4(%rsp)
test   %r15d,%r15d
je     1399 <getNum+0x219>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movslq %r15d,%rax
cmpl   $0x1,0x10(%rsp,%rax,4)
jne    139e <getNum+0x21e>
xor    %eax,%eax
call   10a0 <rand@plt>
movslq %eax,%r15
imul   $0xffffffff92492493,%r15,%rax
shr    $0x20,%rax
add    %r15d,%eax
mov    %eax,%ecx
shr    $0x1f,%ecx
sar    $0x5,%eax
add    %ecx,%eax
imul   $0x38,%eax,%eax
sub    %eax,%r15d
inc    %r15d
jne    1360 <getNum+0x1e0>
jmp    13a6 <getNum+0x226>
xor    %r15d,%r15d
jmp    13a6 <getNum+0x226>
movl   $0x1,0x10(%rsp,%rax,4)
lea    0xc53(%rip),%rdi
lea    0xc5e(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,%r14
mov    $0x1,%ebx
lea    0xc4c(%rip),%r12
jmp    13da <getNum+0x25a>
nopw   0x0(%rax,%rax,1)
add    $0x1,%rbx
cmp    $0x39,%rbx
je     13f2 <getNum+0x272>
cmpl   $0x1,0x10(%rsp,%rbx,4)
jne    13d0 <getNum+0x250>
mov    %r14,%rdi
mov    %r12,%rsi
mov    %ebx,%edx
xor    %eax,%eax
call   1060 <fprintf@plt>
jmp    13d0 <getNum+0x250>
mov    %r14,%rdi
call   1030 <fclose@plt>
mov    %r15d,%eax
add    $0x100,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [13 x i8] c"previous.dat\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [3 x i8] c"%d\00"
@.str.3 = [2 x i8] c"w\00"
@.str.4 = [3 x i8] c"%s\00"
@.str.5 = [1 x i8] zeroinitializer
@.str.6 = [4 x i8] c"%d\0A\00"
define i32 @getNum() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32*
%5 = alloca [57 x i32]
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = call i32 @time(i32* null)
%10 = call i32 @srand(i32 %9)
%11 = call i32 (...) @rand()
%12 = srem i32 %11, 56
%13 = add nsw i32 %12, 1
store i32 %13, i32* %2
store i32 0, i32* %3
%14 = call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %14, i32** %4
%15 = bitcast [57 x i32]* %5 to i8*
br label %16
16: ; preds = %21, %0
%17 = load i32*, i32** %4
%18 = call i32 @feof(i32* %17)
%19 = icmp ne i32 %18, 0
%20 = xor i1 %19, true
br i1 %20, label %21, label %27
21: ; preds = %16
%22 = load i32*, i32** %4
%23 = call i32 @fscanf(i32* %22, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32* %6)
%24 = load i32, i32* %6
%25 = sext i32 %24 to i64
%26 = getelementptr inbounds [57 x i32], [57 x i32]* %5, i64 0, i64 %25
store i32 1, i32* %26
br label %16
27: ; preds = %16
%28 = load i32*, i32** %4
%29 = call i32 @fclose(i32* %28)
store i32 1, i32* %7
store i32 1, i32* %1
br label %30
30: ; preds = %41, %27
%31 = load i32, i32* %1
%32 = icmp slt i32 %31, 57
br i1 %32, label %33, label %44
33: ; preds = %30
%34 = load i32, i32* %1
%35 = sext i32 %34 to i64
%36 = getelementptr inbounds [57 x i32], [57 x i32]* %5, i64 0, i64 %35
%37 = load i32, i32* %36
%38 = icmp eq i32 %37, 0
br i1 %38, label %39, label %40
39: ; preds = %33
store i32 0, i32* %7
br label %44
40: ; preds = %33
br label %41
41: ; preds = %40
%42 = load i32, i32* %1
%43 = add nsw i32 %42, 1
store i32 %43, i32* %1
br label %30
44: ; preds = %39, %30
%45 = load i32, i32* %7
%46 = icmp eq i32 %45, 1
br i1 %46, label %47, label %64
47: ; preds = %44
%48 = call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
store i32* %48, i32** %4
%49 = load i32*, i32** %4
%50 = call i32 (i32*, i8*, ...) @fprintf(i32* %49, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.5, i64 0, i64 0))
%51 = load i32*, i32** %4
%52 = call i32 @fclose(i32* %51)
store i32 1, i32* %1
br label %53
53: ; preds = %60, %47
%54 = load i32, i32* %1
%55 = icmp slt i32 %54, 57
br i1 %55, label %56, label %63
56: ; preds = %53
%57 = load i32, i32* %1
%58 = sext i32 %57 to i64
%59 = getelementptr inbounds [57 x i32], [57 x i32]* %5, i64 0, i64 %58
store i32 0, i32* %59
br label %60
60: ; preds = %56
%61 = load i32, i32* %1
%62 = add nsw i32 %61, 1
store i32 %62, i32* %1
br label %53
63: ; preds = %53
br label %64
64: ; preds = %63, %44
store i32 1, i32* %8
br label %65
65: ; preds = %95, %64
%66 = load i32, i32* %3
%67 = load i32, i32* %2
%68 = icmp ne i32 %66, %67
br i1 %68, label %69, label %96
69: ; preds = %65
store i32 1, i32* %8
store i32 1, i32* %1
br label %70
70: ; preds = %84, %69
%71 = load i32, i32* %1
%72 = icmp slt i32 %71, 57
br i1 %72, label %73, label %87
73: ; preds = %70
%74 = load i32, i32* %2
%75 = sext i32 %74 to i64
%76 = getelementptr inbounds [57 x i32], [57 x i32]* %5, i64 0, i64 %75
%77 = load i32, i32* %76
%78 = icmp eq i32 %77, 1
br i1 %78, label %79, label %83
79: ; preds = %73
store i32 0, i32* %8
%80 = call i32 (...) @rand()
%81 = srem i32 %80, 56
%82 = add nsw i32 %81, 1
store i32 %82, i32* %2
br label %87
83: ; preds = %73
br label %84
84: ; preds = %83
%85 = load i32, i32* %1
%86 = add nsw i32 %85, 1
store i32 %86, i32* %1
br label %70
87: ; preds = %79, %70
%88 = load i32, i32* %8
%89 = icmp eq i32 %88, 1
br i1 %89, label %90, label %95
90: ; preds = %87
%91 = load i32, i32* %2
store i32 %91, i32* %3
%92 = load i32, i32* %3
%93 = sext i32 %92 to i64
%94 = getelementptr inbounds [57 x i32], [57 x i32]* %5, i64 0, i64 %93
store i32 1, i32* %94
br label %95
95: ; preds = %90, %87
br label %65
96: ; preds = %65
%97 = call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
store i32* %97, i32** %4
store i32 1, i32* %1
br label %98
98: ; preds = %112, %96
%99 = load i32, i32* %1
%100 = icmp slt i32 %99, 57
br i1 %100, label %101, label %115
101: ; preds = %98
%102 = load i32, i32* %1
%103 = sext i32 %102 to i64
%104 = getelementptr inbounds [57 x i32], [57 x i32]* %5, i64 0, i64 %103
%105 = load i32, i32* %104
%106 = icmp eq i32 %105, 1
br i1 %106, label %107, label %111
107: ; preds = %101
%108 = load i32*, i32** %4
%109 = load i32, i32* %1
%110 = call i32 (i32*, i8*, ...) @fprintf(i32* %108, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0), i32 %109)
br label %111
111: ; preds = %107, %101
br label %112
112: ; preds = %111
%113 = load i32, i32* %1
%114 = add nsw i32 %113, 1
store i32 %114, i32* %1
br label %98
115: ; preds = %98
%116 = load i32*, i32** %4
%117 = call i32 @fclose(i32* %116)
%118 = load i32, i32* %3
ret i32 %118
}

LLVM IR (-O2):
@.str = [13 x i8] c"previous.dat\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [3 x i8] c"%d\00"
@.str.3 = [2 x i8] c"w\00"
@.str.6 = [4 x i8] c"%d\0A\00"
define i32 @getNum() {
%1 = alloca [57 x i32]
%2 = alloca i32
%3 = tail call i32 @time(i32* null)
%4 = tail call i32 @srand(i32 %3)
%5 = tail call i32 (...) @rand()
%6 = srem i32 %5, 56
%7 = add nsw i32 %6, 1
%8 = tail call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%9 = bitcast [57 x i32]* %1 to i8*
%10 = bitcast i32* %2 to i8*
%11 = call i32 @feof(i32* %8)
%12 = icmp eq i32 %11, 0
br i1 %12, label %13, label %20
13: ; preds = %0, %13
%14 = call i32 @fscanf(i32* %8, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i32* %2)
%15 = load i32, i32* %2
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %16
store i32 1, i32* %17
%18 = call i32 @feof(i32* %8)
%19 = icmp eq i32 %18, 0
br i1 %19, label %13, label %20
20: ; preds = %13, %0
%21 = call i32 @fclose(i32* %8)
br label %40
22: ; preds = %40
%23 = add nuw nsw i64 %41, 1
%24 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %23
%25 = load i32, i32* %24
%26 = icmp eq i32 %25, 0
br i1 %26, label %50, label %27
27: ; preds = %22
%28 = add nuw nsw i64 %41, 2
%29 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %28
%30 = load i32, i32* %29
%31 = icmp eq i32 %30, 0
br i1 %31, label %50, label %32
32: ; preds = %27
%33 = add nuw nsw i64 %41, 3
%34 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %33
%35 = load i32, i32* %34
%36 = icmp eq i32 %35, 0
br i1 %36, label %50, label %37
37: ; preds = %32
%38 = add nuw nsw i64 %41, 4
%39 = icmp eq i64 %38, 57
br i1 %39, label %45, label %40
40: ; preds = %37, %20
%41 = phi i64 [ 1, %20 ], [ %38, %37 ]
%42 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %41
%43 = load i32, i32* %42
%44 = icmp eq i32 %43, 0
br i1 %44, label %50, label %22
45: ; preds = %37
%46 = call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
%47 = call i32 @fclose(i32* %46)
%48 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 1
%49 = bitcast i32* %48 to i8*
br label %50
50: ; preds = %40, %22, %27, %32, %45
%51 = icmp eq i32 %7, 0
br i1 %51, label %65, label %52
52: ; preds = %50, %60
%53 = phi i32 [ %63, %60 ], [ %7, %50 ]
%54 = sext i32 %53 to i64
%55 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %54
%56 = load i32, i32* %55
%57 = icmp eq i32 %56, 1
br i1 %57, label %60, label %58
58: ; preds = %52
%59 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %54
store i32 1, i32* %59
br label %65
60: ; preds = %52
%61 = call i32 (...) @rand()
%62 = srem i32 %61, 56
%63 = add nsw i32 %62, 1
%64 = icmp eq i32 %63, 0
br i1 %64, label %65, label %52
65: ; preds = %60, %58, %50
%66 = phi i32 [ 0, %50 ], [ %53, %58 ], [ %63, %60 ]
%67 = call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
br label %68
68: ; preds = %65, %76
%69 = phi i64 [ 1, %65 ], [ %77, %76 ]
%70 = getelementptr inbounds [57 x i32], [57 x i32]* %1, i64 0, i64 %69
%71 = load i32, i32* %70
%72 = icmp eq i32 %71, 1
br i1 %72, label %73, label %76
73: ; preds = %68
%74 = trunc i64 %69 to i32
%75 = call i32 (i32*, i8*, ...) @fprintf(i32* %67, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0), i32 %74)
br label %76
76: ; preds = %68, %73
%77 = add nuw nsw i64 %69, 1
%78 = icmp eq i64 %77, 57
br i1 %78, label %79, label %68
79: ; preds = %76
%80 = call i32 @fclose(i32* %67)
ret i32 %66
}