#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*/ free(char *);
char *malloc(scalar_t__);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ read_line(char *, int);
int /*<<< orphan*/ scanf(char *, int *);
int /*<<< orphan*/ sprintf(char *, char *, int);
scalar_t__ strcmp(char *, char *);
scalar_t__ strlen(char *);
int /*<<< orphan*/ strncat(char *, char *, scalar_t__);
int /*<<< orphan*/ strncpy(char *, char *, scalar_t__);
int main(void) {
  char *entries[50];
  int reminders = 0;
  while (true) {
    char day_str[(2 + 1)];
    char msg_str[(77 + 1)];
    int i = 0;
    int day;
    if (reminders == 50) {
      printf("Maximum number of entries reached!\n");
      break;
    }
    printf("Enter day and reminder: ");
    scanf("%2d", &day);
    if (day == 0) {
      break;
    }
    sprintf(day_str, "%2d", day);
    read_line(msg_str, (77 + 1));
    for (i = 0; i < reminders; i += 1) {
      if (strcmp(day_str, entries[i]) < 0) {
        break;
      }
    }
    for (int j = reminders; j > i; j -= 1) {
      entries[j] = entries[j - 1];
    }
    entries[i] = malloc(2 + strlen(msg_str) + 1);
    if (entries[i] == NULL) {
      printf("Failed to allocate memory!\n");
      break;
    }
    strncpy(entries[i], day_str, strlen(day_str));
    strncat(entries[i], msg_str, strlen(msg_str));
    reminders += 1;
  }
  printf("Day Reminder\n");
  for (int i = 0; i < reminders; i += 1) {
    printf("%s\n", entries[i]);
  }
  for (int i = 0; i < reminders; i += 1) {
    free(entries[i]);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x240,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x1a4(%rbp)
movl   $0x0,-0x204(%rbp)
cmpl   $0x32,-0x1a4(%rbp)
jne    11e6 <main+0x46>
lea    0xe26(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    13ed <main+0x24d>
lea    0xe37(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xe42(%rip),%rdi
lea    -0x208(%rbp),%rsi
call   10a0 <scanf@plt>
cmpl   $0x0,-0x208(%rbp)
jne    1219 <main+0x79>
jmp    13ed <main+0x24d>
lea    -0x1a7(%rbp),%rdi
mov    -0x208(%rbp),%edx
lea    0xe10(%rip),%rsi
call   10c0 <sprintf@plt>
lea    -0x200(%rbp),%rdi
mov    $0x4e,%esi
call   10b0 <read_line@plt>
movl   $0x0,-0x204(%rbp)
mov    -0x204(%rbp),%eax
cmp    -0x1a4(%rbp),%eax
jge    12a2 <main+0x102>
lea    -0x1a7(%rbp),%rdi
movslq -0x204(%rbp),%rax
mov    -0x1a0(%rbp,%rax,8),%rsi
ff
call   1080 <strcmp@plt>
cmp    $0x0,%rax
jge    1289 <main+0xe9>
jmp    12a2 <main+0x102>
jmp    128e <main+0xee>
mov    -0x204(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x204(%rbp)
jmp    124d <main+0xad>
mov    -0x1a4(%rbp),%eax
mov    %eax,-0x20c(%rbp)
mov    -0x20c(%rbp),%eax
cmp    -0x204(%rbp),%eax
jle    12f6 <main+0x156>
mov    -0x20c(%rbp),%eax
sub    $0x1,%eax
cltq
mov    -0x1a0(%rbp,%rax,8),%rcx
ff
movslq -0x20c(%rbp),%rax
mov    %rcx,-0x1a0(%rbp,%rax,8)
ff
mov    -0x20c(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x20c(%rbp)
jmp    12ae <main+0x10e>
lea    -0x200(%rbp),%rdi
call   1050 <strlen@plt>
mov    %rax,%rdi
add    $0x2,%rdi
add    $0x1,%rdi
call   1090 <malloc@plt>
mov    %rax,%rcx
movslq -0x204(%rbp),%rax
mov    %rcx,-0x1a0(%rbp,%rax,8)
ff
movslq -0x204(%rbp),%rax
cmpq   $0x0,-0x1a0(%rbp,%rax,8)
jne    134d <main+0x1ad>
lea    0xd00(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    13ed <main+0x24d>
movslq -0x204(%rbp),%rax
mov    -0x1a0(%rbp,%rax,8),%rax
ff
mov    %rax,-0x238(%rbp)
lea    -0x1a7(%rbp),%rax
mov    %rax,-0x230(%rbp)
lea    -0x1a7(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x238(%rbp),%rdi
mov    -0x230(%rbp),%rsi
mov    %rax,%rdx
call   1040 <strncpy@plt>
movslq -0x204(%rbp),%rax
mov    -0x1a0(%rbp,%rax,8),%rax
ff
mov    %rax,-0x228(%rbp)
lea    -0x200(%rbp),%rax
mov    %rax,-0x220(%rbp)
lea    -0x200(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x228(%rbp),%rdi
mov    -0x220(%rbp),%rsi
mov    %rax,%rdx
call   1070 <strncat@plt>
mov    -0x1a4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1a4(%rbp)
jmp    11bc <main+0x1c>
lea    0xc69(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x0,-0x210(%rbp)
mov    -0x210(%rbp),%eax
cmp    -0x1a4(%rbp),%eax
jge    1448 <main+0x2a8>
movslq -0x210(%rbp),%rax
mov    -0x1a0(%rbp,%rax,8),%rsi
ff
lea    0xc3e(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x210(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x210(%rbp)
jmp    1405 <main+0x265>
movl   $0x0,-0x214(%rbp)
mov    -0x214(%rbp),%eax
cmp    -0x1a4(%rbp),%eax
jge    148c <main+0x2ec>
movslq -0x214(%rbp),%rax
mov    -0x1a0(%rbp,%rax,8),%rdi
ff
call   1030 <free@plt>
mov    -0x214(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x214(%rbp)
jmp    1452 <main+0x2b2>
xor    %eax,%eax
add    $0x240,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x208,%rsp
lea    0x70(%rsp),%r15
lea    0xe4c(%rip),%rbp
lea    0x1d(%rsp),%rbx
lea    0x20(%rsp),%r12
xor    %eax,%eax
mov    %rax,0x10(%rsp)
xor    %r14d,%r14d
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
lea    0xe09(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %rbp,%rdi
lea    0xc(%rsp),%rsi
call   10b0 <scanf@plt>
mov    0xc(%rsp),%edx
test   %edx,%edx
je     1377 <main+0x1c7>
mov    %rbx,%rdi
mov    %rbp,%rsi
call   10d0 <sprintf@plt>
mov    %r12,%rdi
mov    $0x4e,%esi
call   10c0 <read_line@plt>
xor    %ebp,%ebp
test   %r14,%r14
je     125e <main+0xae>
cs nopw 0x0(%rax,%rax,1)
mov    0x70(%rsp,%rbp,8),%rsi
mov    %rbx,%rdi
call   1090 <strcmp@plt>
test   %rax,%rax
js     125e <main+0xae>
add    $0x1,%rbp
cmp    %rbp,%r14
jne    1240 <main+0x90>
mov    %r14,%rbp
mov    %ebp,%r13d
cmp    %r13,%r14
jbe    12dd <main+0x12d>
movslq %r13d,%rax
mov    %r14d,%esi
sub    %eax,%esi
mov    %rax,%rcx
not    %rcx
add    %r14,%rcx
mov    %r14,%rdx
test   $0x3,%sil
je     12b7 <main+0x107>
mov    %r14d,%edx
sub    %r13b,%dl
movzbl %dl,%esi
and    $0x3,%esi
neg    %rsi
xor    %edx,%edx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    -0x8(%r15,%rdx,8),%rdi
mov    %rdi,(%r15,%rdx,8)
add    $0xffffffffffffffff,%rdx
cmp    %rdx,%rsi
jne    12a0 <main+0xf0>
sub    0x10(%rsp),%rdx
cmp    $0x3,%rcx
jb     12dd <main+0x12d>
nopl   (%rax)
movups 0x50(%rsp,%rdx,8),%xmm0
movups 0x60(%rsp,%rdx,8),%xmm1
movups %xmm1,0x68(%rsp,%rdx,8)
movups %xmm0,0x58(%rsp,%rdx,8)
add    $0xfffffffffffffffc,%rdx
cmp    %rax,%rdx
jg     12c0 <main+0x110>
lea    0x20(%rsp),%r12
mov    %r12,%rdi
call   1060 <strlen@plt>
lea    0x3(%rax),%rdi
call   10a0 <malloc@plt>
mov    %rax,0x70(%rsp,%r13,8)
test   %rax,%rax
je     136b <main+0x1bb>
mov    %rax,%rbp
mov    %rbx,%rdi
call   1060 <strlen@plt>
mov    %rbp,%rdi
mov    %rbx,%rsi
mov    %rax,%rdx
call   1040 <strncpy@plt>
mov    %r12,%rdi
call   1060 <strlen@plt>
mov    %rbp,%rdi
mov    %r12,%rsi
mov    %rax,%rdx
call   1080 <strncat@plt>
add    $0x1,%r14
add    $0x8,%r15
addq   $0xffffffffffffffff,0x10(%rsp)
cmp    $0x32,%r14
lea    0xcd4(%rip),%rbp
jne    11f0 <main+0x40>
lea    0xcf3(%rip),%rdi
call   1050 <puts@plt>
lea    0xcbf(%rip),%rdi
call   1050 <puts@plt>
mov    $0x32,%r14d
jmp    1388 <main+0x1d8>
lea    0xcb8(%rip),%rdi
call   1050 <puts@plt>
lea    0xc9f(%rip),%rdi
call   1050 <puts@plt>
test   %r14d,%r14d
je     13c3 <main+0x213>
mov    %r14d,%ebx
xor    %ebp,%ebp
nopl   (%rax)
mov    0x70(%rsp,%rbp,8),%rdi
call   1050 <puts@plt>
add    $0x1,%rbp
cmp    %rbp,%rbx
jne    1390 <main+0x1e0>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nop
mov    0x70(%rsp,%rbp,8),%rdi
call   1030 <free@plt>
add    $0x1,%rbp
cmp    %rbp,%rbx
jne    13b0 <main+0x200>
xor    %eax,%eax
add    $0x208,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [36 x i8] c"Maximum number of entries reached!\0A\00"
@.str.1 = [25 x i8] c"Enter day and reminder: \00"
@.str.2 = [4 x i8] c"%2d\00"
@.str.3 = [28 x i8] c"Failed to allocate memory!\0A\00"
@.str.4 = [14 x i8] c"Day Reminder\0A\00"
@.str.5 = [4 x i8] c"%s\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [50 x i8*]
%3 = alloca i32
%4 = alloca [3 x i8]
%5 = alloca [78 x i8]
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %3
br label %11
11: ; preds = %0, %79
store i32 0, i32* %6
%12 = load i32, i32* %3
%13 = icmp eq i32 %12, 50
br i1 %13, label %14, label %16
14: ; preds = %11
%15 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str, i64 0, i64 0))
br label %98
16: ; preds = %11
%17 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0))
%18 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32* %7)
%19 = load i32, i32* %7
%20 = icmp eq i32 %19, 0
br i1 %20, label %21, label %22
21: ; preds = %16
br label %98
22: ; preds = %16
%23 = getelementptr inbounds [3 x i8], [3 x i8]* %4, i64 0, i64 0
%24 = load i32, i32* %7
%25 = call i32 @sprintf(i8* %23, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %24)
%26 = getelementptr inbounds [78 x i8], [78 x i8]* %5, i64 0, i64 0
%27 = call i32 @read_line(i8* %26, i32 78)
store i32 0, i32* %6
br label %28
28: ; preds = %42, %22
%29 = load i32, i32* %6
%30 = load i32, i32* %3
%31 = icmp slt i32 %29, %30
br i1 %31, label %32, label %45
32: ; preds = %28
%33 = getelementptr inbounds [3 x i8], [3 x i8]* %4, i64 0, i64 0
%34 = load i32, i32* %6
%35 = sext i32 %34 to i64
%36 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %35
%37 = load i8*, i8** %36
%38 = call i64 @strcmp(i8* %33, i8* %37)
%39 = icmp slt i64 %38, 0
br i1 %39, label %40, label %41
40: ; preds = %32
br label %45
41: ; preds = %32
br label %42
42: ; preds = %41
%43 = load i32, i32* %6
%44 = add nsw i32 %43, 1
store i32 %44, i32* %6
br label %28
45: ; preds = %40, %28
%46 = load i32, i32* %3
store i32 %46, i32* %8
br label %47
47: ; preds = %60, %45
%48 = load i32, i32* %8
%49 = load i32, i32* %6
%50 = icmp sgt i32 %48, %49
br i1 %50, label %51, label %63
51: ; preds = %47
%52 = load i32, i32* %8
%53 = sub nsw i32 %52, 1
%54 = sext i32 %53 to i64
%55 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %54
%56 = load i8*, i8** %55
%57 = load i32, i32* %8
%58 = sext i32 %57 to i64
%59 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %58
store i8* %56, i8** %59
br label %60
60: ; preds = %51
%61 = load i32, i32* %8
%62 = sub nsw i32 %61, 1
store i32 %62, i32* %8
br label %47
63: ; preds = %47
%64 = getelementptr inbounds [78 x i8], [78 x i8]* %5, i64 0, i64 0
%65 = call i64 @strlen(i8* %64)
%66 = add nsw i64 2, %65
%67 = add nsw i64 %66, 1
%68 = call i8* @malloc(i64 %67)
%69 = load i32, i32* %6
%70 = sext i32 %69 to i64
%71 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %70
store i8* %68, i8** %71
%72 = load i32, i32* %6
%73 = sext i32 %72 to i64
%74 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %73
%75 = load i8*, i8** %74
%76 = icmp eq i8* %75, null
br i1 %76, label %77, label %79
77: ; preds = %63
%78 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.3, i64 0, i64 0))
br label %98
79: ; preds = %63
%80 = load i32, i32* %6
%81 = sext i32 %80 to i64
%82 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %81
%83 = load i8*, i8** %82
%84 = getelementptr inbounds [3 x i8], [3 x i8]* %4, i64 0, i64 0
%85 = getelementptr inbounds [3 x i8], [3 x i8]* %4, i64 0, i64 0
%86 = call i64 @strlen(i8* %85)
%87 = call i32 @strncpy(i8* %83, i8* %84, i64 %86)
%88 = load i32, i32* %6
%89 = sext i32 %88 to i64
%90 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %89
%91 = load i8*, i8** %90
%92 = getelementptr inbounds [78 x i8], [78 x i8]* %5, i64 0, i64 0
%93 = getelementptr inbounds [78 x i8], [78 x i8]* %5, i64 0, i64 0
%94 = call i64 @strlen(i8* %93)
%95 = call i32 @strncat(i8* %91, i8* %92, i64 %94)
%96 = load i32, i32* %3
%97 = add nsw i32 %96, 1
store i32 %97, i32* %3
br label %11
98: ; preds = %77, %21, %14
%99 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.4, i64 0, i64 0))
store i32 0, i32* %9
br label %100
100: ; preds = %110, %98
%101 = load i32, i32* %9
%102 = load i32, i32* %3
%103 = icmp slt i32 %101, %102
br i1 %103, label %104, label %113
104: ; preds = %100
%105 = load i32, i32* %9
%106 = sext i32 %105 to i64
%107 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %106
%108 = load i8*, i8** %107
%109 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.5, i64 0, i64 0), i8* %108)
br label %110
110: ; preds = %104
%111 = load i32, i32* %9
%112 = add nsw i32 %111, 1
store i32 %112, i32* %9
br label %100
113: ; preds = %100
store i32 0, i32* %10
br label %114
114: ; preds = %124, %113
%115 = load i32, i32* %10
%116 = load i32, i32* %3
%117 = icmp slt i32 %115, %116
br i1 %117, label %118, label %127
118: ; preds = %114
%119 = load i32, i32* %10
%120 = sext i32 %119 to i64
%121 = getelementptr inbounds [50 x i8*], [50 x i8*]* %2, i64 0, i64 %120
%122 = load i8*, i8** %121
%123 = call i32 @free(i8* %122)
br label %124
124: ; preds = %118
%125 = load i32, i32* %10
%126 = add nsw i32 %125, 1
store i32 %126, i32* %10
br label %114
127: ; preds = %114
ret i32 0
}

LLVM IR (-O2):
@.str.1 = [25 x i8] c"Enter day and reminder: \00"
@.str.2 = [4 x i8] c"%2d\00"
@str = [13 x i8] c"Day Reminder\00"
@str.6 = [27 x i8] c"Failed to allocate memory!\00"
@str.7 = [35 x i8] c"Maximum number of entries reached!\00"
define i32 @main() {
%1 = alloca [50 x i8*]
%2 = alloca [3 x i8]
%3 = alloca [78 x i8]
%4 = alloca i32
%5 = bitcast [50 x i8*]* %1 to i8*
%6 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%7 = getelementptr inbounds [78 x i8], [78 x i8]* %3, i64 0, i64 0
%8 = bitcast i32* %4 to i8*
br label %12
9: ; preds = %84
%10 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([35 x i8], [35 x i8]* @str.7, i64 0, i64 0))
%11 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str, i64 0, i64 0))
br label %95
12: ; preds = %0, %84
%13 = phi i64 [ 0, %0 ], [ %89, %84 ]
%14 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0))
%15 = call i32 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32* %4)
%16 = load i32, i32* %4
%17 = icmp eq i32 %16, 0
br i1 %17, label %91, label %18
18: ; preds = %12
%19 = call i32 @sprintf(i8* %6, i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %16)
%20 = call i32 @read_line(i8* %7, i32 78)
%21 = icmp eq i64 %13, 0
br i1 %21, label %34, label %22
22: ; preds = %18, %28
%23 = phi i64 [ %29, %28 ], [ 0, %18 ]
%24 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %23
%25 = load i8*, i8** %24
%26 = call i64 @strcmp(i8* %6, i8* %25)
%27 = icmp slt i64 %26, 0
br i1 %27, label %31, label %28
28: ; preds = %22
%29 = add nuw nsw i64 %23, 1
%30 = icmp eq i64 %29, %13
br i1 %30, label %31, label %22
31: ; preds = %22, %28
%32 = phi i64 [ %13, %28 ], [ %23, %22 ]
%33 = trunc i64 %32 to i32
br label %34
34: ; preds = %31, %18
%35 = phi i32 [ 0, %18 ], [ %33, %31 ]
%36 = zext i32 %35 to i64
%37 = icmp ugt i64 %13, %36
br i1 %37, label %38, label %57
38: ; preds = %34
%39 = sext i32 %35 to i64
%40 = sub i64 %13, %39
%41 = xor i64 %39, -1
%42 = add i64 %13, %41
%43 = and i64 %40, 3
%44 = icmp eq i64 %43, 0
br i1 %44, label %54, label %45
45: ; preds = %38, %45
%46 = phi i64 [ %48, %45 ], [ %13, %38 ]
%47 = phi i64 [ %52, %45 ], [ 0, %38 ]
%48 = add nsw i64 %46, -1
%49 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %48
%50 = load i8*, i8** %49
%51 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %46
store i8* %50, i8** %51
%52 = add i64 %47, 1
%53 = icmp eq i64 %52, %43
br i1 %53, label %54, label %45
54: ; preds = %45, %38
%55 = phi i64 [ %13, %38 ], [ %48, %45 ]
%56 = icmp ult i64 %42, 3
br i1 %56, label %57, label %63
57: ; preds = %54, %63, %34
%58 = call i64 @strlen(i8* %7)
%59 = add nsw i64 %58, 3
%60 = call i8* @malloc(i64 %59)
%61 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %36
store i8* %60, i8** %61
%62 = icmp eq i8* %60, null
br i1 %62, label %82, label %84
63: ; preds = %54, %63
%64 = phi i64 [ %77, %63 ], [ %55, %54 ]
%65 = add nsw i64 %64, -1
%66 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %65
%67 = load i8*, i8** %66
%68 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %64
store i8* %67, i8** %68
%69 = add nsw i64 %64, -2
%70 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %69
%71 = load i8*, i8** %70
%72 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %65
store i8* %71, i8** %72
%73 = add nsw i64 %64, -3
%74 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %73
%75 = load i8*, i8** %74
%76 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %69
store i8* %75, i8** %76
%77 = add nsw i64 %64, -4
%78 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %77
%79 = load i8*, i8** %78
%80 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %73
store i8* %79, i8** %80
%81 = icmp sgt i64 %77, %39
br i1 %81, label %63, label %57
82: ; preds = %57
%83 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str.6, i64 0, i64 0))
br label %91
84: ; preds = %57
%85 = call i64 @strlen(i8* %6)
%86 = call i32 @strncpy(i8* %60, i8* %6, i64 %85)
%87 = call i64 @strlen(i8* %7)
%88 = call i32 @strncat(i8* %60, i8* %7, i64 %87)
%89 = add nuw nsw i64 %13, 1
%90 = icmp eq i64 %89, 50
br i1 %90, label %9, label %12
91: ; preds = %12, %82
%92 = trunc i64 %13 to i32
%93 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str, i64 0, i64 0))
%94 = icmp eq i32 %92, 0
br i1 %94, label %107, label %95
95: ; preds = %9, %91
%96 = phi i32 [ 50, %9 ], [ %92, %91 ]
%97 = zext i32 %96 to i64
br label %100
98: ; preds = %100
%99 = zext i32 %96 to i64
br label %108
100: ; preds = %95, %100
%101 = phi i64 [ 0, %95 ], [ %105, %100 ]
%102 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %101
%103 = load i8*, i8** %102
%104 = call i32 @puts(i8* dereferenceable(1) %103)
%105 = add nuw nsw i64 %101, 1
%106 = icmp eq i64 %105, %97
br i1 %106, label %98, label %100
107: ; preds = %108, %91
ret i32 0
108: ; preds = %98, %108
%109 = phi i64 [ 0, %98 ], [ %113, %108 ]
%110 = getelementptr inbounds [50 x i8*], [50 x i8*]* %1, i64 0, i64 %109
%111 = load i8*, i8** %110
%112 = call i32 @free(i8* %111)
%113 = add nuw nsw i64 %109, 1
%114 = icmp eq i64 %113, %99
br i1 %114, label %107, label %108
}