#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 rand();
int /*<<< orphan*/ srand(unsigned int);
scalar_t__ time(int /*<<< orphan*/ *);
int main(void) {
  srand((unsigned)time(NULL));
  int board[10][10];
  int x = rand() % 10;
  int y = rand() % 10;
  int letter = 'A';
  int move, up, down, left, right;
  for (int i = 0; i < 10; i += 1) {
    for (int j = 0; j < 10; j += 1) {
      board[i][j] = '+';
    }
  }
  while (letter <= 'Z') {
    board[x][y] = letter;
    letter += 1;
    if ((y - 1 >= 0) && (board[x][y - 1] == '+')) {
      up = 1;
    } else {
      up = 0;
    }
    if ((y + 1 <= 9) && (board[x][y + 1] == '+')) {
      down = 1;
    } else {
      down = 0;
    }
    if ((x - 1 >= 0) && (board[x - 1][y] == '+')) {
      left = 1;
    } else {
      left = 0;
    }
    if ((x + 1 >= 0) && (board[x + 1][y] == '+')) {
      right = 1;
    } else {
      right = 0;
    }
    if (up == 0 && down == 0 && left == 0 && right == 0) {
      break;
    }
    while (up == 1 || down == 1 || left == 1 || right == 1) {
      move = rand() % 4;
      if (move == 0 && up == 1) {
        y -= 1;
        break;
      } else if (move == 1 && down == 1) {
        y += 1;
        break;
      } else if (move == 2 && left == 1) {
        x -= 1;
        break;
      } else if (move == 3 && right == 1) {
        x += 1;
        break;
      } else {
        continue;
      }
    }
  }
  for (int i = 0; i < 10; i += 1) {
    printf("\t");
    for (int j = 0; j < 10; j += 1) {
      printf("%c ", board[i][j]);
    }
    printf("\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1e0,%rsp
movl   $0x0,-0x4(%rbp)
xor    %eax,%eax
mov    %eax,%edi
call   1050 <time@plt>
mov    %eax,%edi
call   1040 <srand@plt>
mov    $0x0,%al
call   1060 <rand@plt>
mov    $0xa,%ecx
cltd
idiv   %ecx
mov    %edx,-0x1a4(%rbp)
mov    $0x0,%al
call   1060 <rand@plt>
mov    $0xa,%ecx
cltd
idiv   %ecx
mov    %edx,-0x1a8(%rbp)
movl   $0x41,-0x1ac(%rbp)
movl   $0x0,-0x1c4(%rbp)
cmpl   $0xa,-0x1c4(%rbp)
jge    1214 <main+0xd4>
movl   $0x0,-0x1c8(%rbp)
cmpl   $0xa,-0x1c8(%rbp)
jge    11fb <main+0xbb>
movslq -0x1c4(%rbp),%rcx
lea    -0x1a0(%rbp),%rax
imul   $0x28,%rcx,%rcx
add    %rcx,%rax
movslq -0x1c8(%rbp),%rcx
movl   $0x2b,(%rax,%rcx,4)
mov    -0x1c8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c8(%rbp)
jmp    11b7 <main+0x77>
jmp    1200 <main+0xc0>
mov    -0x1c4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c4(%rbp)
jmp    11a0 <main+0x60>
jmp    1219 <main+0xd9>
cmpl   $0x5a,-0x1ac(%rbp)
jg     1529 <main+0x3e9>
mov    -0x1ac(%rbp),%edx
movslq -0x1a4(%rbp),%rcx
lea    -0x1a0(%rbp),%rax
imul   $0x28,%rcx,%rcx
add    %rcx,%rax
movslq -0x1a8(%rbp),%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x1ac(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1ac(%rbp)
mov    -0x1a8(%rbp),%eax
sub    $0x1,%eax
cmp    $0x0,%eax
jl     12a6 <main+0x166>
movslq -0x1a4(%rbp),%rcx
lea    -0x1a0(%rbp),%rax
imul   $0x28,%rcx,%rcx
add    %rcx,%rax
mov    -0x1a8(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
cmpl   $0x2b,(%rax,%rcx,4)
jne    12a6 <main+0x166>
movl   $0x1,-0x1b4(%rbp)
jmp    12b0 <main+0x170>
movl   $0x0,-0x1b4(%rbp)
mov    -0x1a8(%rbp),%eax
add    $0x1,%eax
cmp    $0x9,%eax
jg     12fc <main+0x1bc>
movslq -0x1a4(%rbp),%rcx
lea    -0x1a0(%rbp),%rax
imul   $0x28,%rcx,%rcx
add    %rcx,%rax
mov    -0x1a8(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
cmpl   $0x2b,(%rax,%rcx,4)
jne    12fc <main+0x1bc>
movl   $0x1,-0x1b8(%rbp)
jmp    1306 <main+0x1c6>
movl   $0x0,-0x1b8(%rbp)
mov    -0x1a4(%rbp),%eax
sub    $0x1,%eax
cmp    $0x0,%eax
jl     1352 <main+0x212>
mov    -0x1a4(%rbp),%eax
sub    $0x1,%eax
movslq %eax,%rcx
lea    -0x1a0(%rbp),%rax
imul   $0x28,%rcx,%rcx
add    %rcx,%rax
movslq -0x1a8(%rbp),%rcx
cmpl   $0x2b,(%rax,%rcx,4)
jne    1352 <main+0x212>
movl   $0x1,-0x1bc(%rbp)
jmp    135c <main+0x21c>
movl   $0x0,-0x1bc(%rbp)
mov    -0x1a4(%rbp),%eax
add    $0x1,%eax
cmp    $0x0,%eax
jl     13a8 <main+0x268>
mov    -0x1a4(%rbp),%eax
add    $0x1,%eax
movslq %eax,%rcx
lea    -0x1a0(%rbp),%rax
imul   $0x28,%rcx,%rcx
add    %rcx,%rax
movslq -0x1a8(%rbp),%rcx
cmpl   $0x2b,(%rax,%rcx,4)
jne    13a8 <main+0x268>
movl   $0x1,-0x1c0(%rbp)
jmp    13b2 <main+0x272>
movl   $0x0,-0x1c0(%rbp)
cmpl   $0x0,-0x1b4(%rbp)
jne    13eb <main+0x2ab>
cmpl   $0x0,-0x1b8(%rbp)
jne    13eb <main+0x2ab>
cmpl   $0x0,-0x1bc(%rbp)
jne    13eb <main+0x2ab>
cmpl   $0x0,-0x1c0(%rbp)
jne    13eb <main+0x2ab>
jmp    1529 <main+0x3e9>
jmp    13f0 <main+0x2b0>
mov    $0x1,%al
cmpl   $0x1,-0x1b4(%rbp)
mov    %al,-0x1d1(%rbp)
je     143f <main+0x2ff>
mov    $0x1,%al
cmpl   $0x1,-0x1b8(%rbp)
mov    %al,-0x1d1(%rbp)
je     143f <main+0x2ff>
mov    $0x1,%al
cmpl   $0x1,-0x1bc(%rbp)
mov    %al,-0x1d1(%rbp)
je     143f <main+0x2ff>
cmpl   $0x1,-0x1c0(%rbp)
sete   %al
mov    %al,-0x1d1(%rbp)
mov    -0x1d1(%rbp),%al
test   $0x1,%al
jne    1452 <main+0x312>
jmp    1524 <main+0x3e4>
mov    $0x0,%al
call   1060 <rand@plt>
mov    $0x4,%ecx
cltd
idiv   %ecx
mov    %edx,-0x1b0(%rbp)
cmpl   $0x0,-0x1b0(%rbp)
jne    1495 <main+0x355>
cmpl   $0x1,-0x1b4(%rbp)
jne    1495 <main+0x355>
mov    -0x1a8(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x1a8(%rbp)
jmp    1524 <main+0x3e4>
cmpl   $0x1,-0x1b0(%rbp)
jne    14c3 <main+0x383>
cmpl   $0x1,-0x1b8(%rbp)
jne    14c3 <main+0x383>
mov    -0x1a8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1a8(%rbp)
jmp    1524 <main+0x3e4>
cmpl   $0x2,-0x1b0(%rbp)
jne    14f1 <main+0x3b1>
cmpl   $0x1,-0x1bc(%rbp)
jne    14f1 <main+0x3b1>
mov    -0x1a4(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x1a4(%rbp)
jmp    1524 <main+0x3e4>
cmpl   $0x3,-0x1b0(%rbp)
jne    151f <main+0x3df>
cmpl   $0x1,-0x1c0(%rbp)
jne    151f <main+0x3df>
mov    -0x1a4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1a4(%rbp)
jmp    1524 <main+0x3e4>
jmp    13f0 <main+0x2b0>
jmp    1219 <main+0xd9>
movl   $0x0,-0x1cc(%rbp)
cmpl   $0xa,-0x1cc(%rbp)
jge    15c8 <main+0x488>
lea    0xab9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x1d0(%rbp)
cmpl   $0xa,-0x1d0(%rbp)
jge    15a6 <main+0x466>
movslq -0x1cc(%rbp),%rcx
lea    -0x1a0(%rbp),%rax
imul   $0x28,%rcx,%rcx
add    %rcx,%rax
movslq -0x1d0(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
lea    0xa77(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x1d0(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1d0(%rbp)
jmp    1558 <main+0x418>
lea    0xa59(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x1cc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1cc(%rbp)
jmp    1533 <main+0x3f3>
xor    %eax,%eax
add    $0x1e0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x1b8,%rsp
xor    %edi,%edi
call   1060 <time@plt>
mov    %eax,%edi
call   1050 <srand@plt>
xor    %eax,%eax
call   1070 <rand@plt>
mov    %eax,%ebx
xor    %eax,%eax
call   1070 <rand@plt>
movaps 0xe7a(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
movaps %xmm0,0x30(%rsp)
movabs $0x2b0000002b,%rcx
mov    %rcx,0x40(%rsp)
movups %xmm0,0x48(%rsp)
movups %xmm0,0x58(%rsp)
mov    %rcx,0x68(%rsp)
movaps %xmm0,0x70(%rsp)
movaps %xmm0,0x80(%rsp)
mov    %rcx,0x90(%rsp)
movups %xmm0,0x98(%rsp)
movups %xmm0,0xa8(%rsp)
mov    %rcx,0xb8(%rsp)
movaps %xmm0,0xc0(%rsp)
movaps %xmm0,0xd0(%rsp)
mov    %rcx,0xe0(%rsp)
movups %xmm0,0xe8(%rsp)
movups %xmm0,0xf8(%rsp)
mov    %rcx,0x108(%rsp)
movaps %xmm0,0x110(%rsp)
movaps %xmm0,0x120(%rsp)
mov    %rcx,0x130(%rsp)
movups %xmm0,0x138(%rsp)
movups %xmm0,0x148(%rsp)
mov    %rcx,0x158(%rsp)
movaps %xmm0,0x160(%rsp)
movaps %xmm0,0x170(%rsp)
mov    %rcx,0x180(%rsp)
movups %xmm0,0x188(%rsp)
movups %xmm0,0x198(%rsp)
mov    %rcx,0x1a8(%rsp)
movslq %ebx,%r12
imul   $0x66666667,%r12,%rcx
mov    %rcx,%rdx
shr    $0x3f,%rdx
shr    $0x20,%rcx
sar    $0x2,%ecx
add    %edx,%ecx
add    %ecx,%ecx
lea    (%rcx,%rcx,4),%ecx
sub    %ecx,%r12d
movslq %eax,%r8
imul   $0x66666667,%r8,%rax
mov    %rax,%rcx
shr    $0x3f,%rcx
shr    $0x20,%rax
sar    $0x2,%eax
add    %ecx,%eax
add    %eax,%eax
lea    (%rax,%rax,4),%eax
sub    %eax,%r8d
mov    $0x41,%ebp
jmp    12c9 <main+0x179>
mov    0x10(%rsp),%eax
mov    %eax,%r8d
add    $0x1,%ebp
cmp    $0x5b,%ebp
je     1425 <main+0x2d5>
movslq %r12d,%rcx
movslq %r8d,%rax
lea    (%rcx,%rcx,4),%rcx
lea    (%rsp,%rcx,8),%rdx
add    $0x20,%rdx
mov    %ebp,(%rdx,%rax,4)
lea    -0x1(%rax),%r9d
test   %eax,%eax
jle    1300 <main+0x1b0>
mov    %r9d,%ecx
cmpl   $0x2b,(%rdx,%rcx,4)
jne    1300 <main+0x1b0>
mov    $0x1,%bl
xor    %ecx,%ecx
jmp    1304 <main+0x1b4>
cs nopw 0x0(%rax,%rax,1)
nop
mov    $0x1,%cl
xor    %ebx,%ebx
lea    0x1(%r8),%r10d
cmp    $0x8,%r8d
jg     1320 <main+0x1d0>
movslq %r10d,%rsi
cmpl   $0x2b,(%rdx,%rsi,4)
jne    1320 <main+0x1d0>
mov    $0x1,%r15b
xor    %r11d,%r11d
jmp    1326 <main+0x1d6>
nop
mov    $0x1,%r11b
xor    %r15d,%r15d
lea    -0x1(%r12),%edx
test   %r12d,%r12d
mov    %edx,0x14(%rsp)
jle    1360 <main+0x210>
mov    %edx,%edx
lea    (%rdx,%rdx,4),%rdx
lea    (%rsp,%rdx,8),%rdx
add    $0x20,%rdx
cmpl   $0x2b,(%rdx,%rax,4)
sete   %r14b
setne  %dl
lea    0x1(%r12),%esi
jmp    1370 <main+0x220>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    0x1(%r12),%esi
mov    $0x1,%dl
xor    %r14d,%r14d
cmp    $0xffffffff,%r12d
jl     1387 <main+0x237>
mov    %esi,%edi
lea    (%rdi,%rdi,4),%rdi
lea    (%rsp,%rdi,8),%rdi
add    $0x20,%rdi
mov    $0x1,%r13b
cmpl   $0x2b,(%rdi,%rax,4)
je     13aa <main+0x25a>
and    %r11b,%cl
cmp    $0x1,%cl
jne    1397 <main+0x247>
test   %dl,%dl
jne    1425 <main+0x2d5>
mov    %ebx,%eax
or     %r15b,%al
or     %r14b,%al
cmp    $0x1,%al
jne    12bd <main+0x16d>
xor    %r13d,%r13d
mov    %esi,0x8(%rsp)
mov    %r10d,0xc(%rsp)
mov    %r9d,0x10(%rsp)
mov    %r8,0x18(%rsp)
nopl   (%rax)
xor    %eax,%eax
call   1070 <rand@plt>
lea    0x3(%rax),%ecx
test   %eax,%eax
cmovns %eax,%ecx
and    $0xfffffffc,%ecx
sub    %ecx,%eax
sete   %cl
test   %cl,%bl
jne    12b6 <main+0x166>
cmp    $0x1,%eax
sete   %cl
test   %cl,%r15b
jne    140b <main+0x2bb>
cmp    $0x2,%eax
sete   %cl
test   %cl,%r14b
jne    1414 <main+0x2c4>
cmp    $0x3,%eax
setne  %al
mov    %r13d,%ecx
xor    $0x1,%cl
or     %al,%cl
jne    13c0 <main+0x270>
mov    0x8(%rsp),%eax
jmp    1418 <main+0x2c8>
mov    0xc(%rsp),%eax
jmp    12ba <main+0x16a>
mov    0x14(%rsp),%eax
mov    %eax,%r12d
mov    0x18(%rsp),%r8
jmp    12bd <main+0x16d>
mov    $0x24,%ebp
lea    0xbdf(%rip),%rbx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    $0x9,%edi
call   1030 <putchar@plt>
mov    -0x4(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    (%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x4(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x8(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0xc(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x10(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x14(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x18(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x1c(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x20(%rsp,%rbp,1),%esi
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x28,%rbp
cmp    $0x1b4,%rbp
jne    1440 <main+0x2f0>
xor    %eax,%eax
add    $0x1b8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [2 x i8] c"\09\00"
@.str.1 = [4 x i8] c"%c \00"
@.str.2 = [2 x i8] c"\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [10 x [10 x i32]]
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
store i32 0, i32* %1
%15 = call i64 @time(i32* null)
%16 = trunc i64 %15 to i32
%17 = call i32 @srand(i32 %16)
%18 = call i32 (...) @rand()
%19 = srem i32 %18, 10
store i32 %19, i32* %3
%20 = call i32 (...) @rand()
%21 = srem i32 %20, 10
store i32 %21, i32* %4
store i32 65, i32* %5
store i32 0, i32* %11
br label %22
22: ; preds = %40, %0
%23 = load i32, i32* %11
%24 = icmp slt i32 %23, 10
br i1 %24, label %25, label %43
25: ; preds = %22
store i32 0, i32* %12
br label %26
26: ; preds = %36, %25
%27 = load i32, i32* %12
%28 = icmp slt i32 %27, 10
br i1 %28, label %29, label %39
29: ; preds = %26
%30 = load i32, i32* %11
%31 = sext i32 %30 to i64
%32 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %2, i64 0, i64 %31
%33 = load i32, i32* %12
%34 = sext i32 %33 to i64
%35 = getelementptr inbounds [10 x i32], [10 x i32]* %32, i64 0, i64 %34
store i32 43, i32* %35
br label %36
36: ; preds = %29
%37 = load i32, i32* %12
%38 = add nsw i32 %37, 1
store i32 %38, i32* %12
br label %26
39: ; preds = %26
br label %40
40: ; preds = %39
%41 = load i32, i32* %11
%42 = add nsw i32 %41, 1
store i32 %42, i32* %11
br label %22
43: ; preds = %22
br label %44
44: ; preds = %187, %43
%45 = load i32, i32* %5
%46 = icmp sle i32 %45, 90
br i1 %46, label %47, label %188
47: ; preds = %44
%48 = load i32, i32* %5
%49 = load i32, i32* %3
%50 = sext i32 %49 to i64
%51 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %2, i64 0, i64 %50
%52 = load i32, i32* %4
%53 = sext i32 %52 to i64
%54 = getelementptr inbounds [10 x i32], [10 x i32]* %51, i64 0, i64 %53
store i32 %48, i32* %54
%55 = load i32, i32* %5
%56 = add nsw i32 %55, 1
store i32 %56, i32* %5
%57 = load i32, i32* %4
%58 = sub nsw i32 %57, 1
%59 = icmp sge i32 %58, 0
br i1 %59, label %60, label %71
60: ; preds = %47
%61 = load i32, i32* %3
%62 = sext i32 %61 to i64
%63 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %2, i64 0, i64 %62
%64 = load i32, i32* %4
%65 = sub nsw i32 %64, 1
%66 = sext i32 %65 to i64
%67 = getelementptr inbounds [10 x i32], [10 x i32]* %63, i64 0, i64 %66
%68 = load i32, i32* %67
%69 = icmp eq i32 %68, 43
br i1 %69, label %70, label %71
70: ; preds = %60
store i32 1, i32* %7
br label %72
71: ; preds = %60, %47
store i32 0, i32* %7
br label %72
72: ; preds = %71, %70
%73 = load i32, i32* %4
%74 = add nsw i32 %73, 1
%75 = icmp sle i32 %74, 9
br i1 %75, label %76, label %87
76: ; preds = %72
%77 = load i32, i32* %3
%78 = sext i32 %77 to i64
%79 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %2, i64 0, i64 %78
%80 = load i32, i32* %4
%81 = add nsw i32 %80, 1
%82 = sext i32 %81 to i64
%83 = getelementptr inbounds [10 x i32], [10 x i32]* %79, i64 0, i64 %82
%84 = load i32, i32* %83
%85 = icmp eq i32 %84, 43
br i1 %85, label %86, label %87
86: ; preds = %76
store i32 1, i32* %8
br label %88
87: ; preds = %76, %72
store i32 0, i32* %8
br label %88
88: ; preds = %87, %86
%89 = load i32, i32* %3
%90 = sub nsw i32 %89, 1
%91 = icmp sge i32 %90, 0
br i1 %91, label %92, label %103
92: ; preds = %88
%93 = load i32, i32* %3
%94 = sub nsw i32 %93, 1
%95 = sext i32 %94 to i64
%96 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %2, i64 0, i64 %95
%97 = load i32, i32* %4
%98 = sext i32 %97 to i64
%99 = getelementptr inbounds [10 x i32], [10 x i32]* %96, i64 0, i64 %98
%100 = load i32, i32* %99
%101 = icmp eq i32 %100, 43
br i1 %101, label %102, label %103
102: ; preds = %92
store i32 1, i32* %9
br label %104
103: ; preds = %92, %88
store i32 0, i32* %9
br label %104
104: ; preds = %103, %102
%105 = load i32, i32* %3
%106 = add nsw i32 %105, 1
%107 = icmp sge i32 %106, 0
br i1 %107, label %108, label %119
108: ; preds = %104
%109 = load i32, i32* %3
%110 = add nsw i32 %109, 1
%111 = sext i32 %110 to i64
%112 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %2, i64 0, i64 %111
%113 = load i32, i32* %4
%114 = sext i32 %113 to i64
%115 = getelementptr inbounds [10 x i32], [10 x i32]* %112, i64 0, i64 %114
%116 = load i32, i32* %115
%117 = icmp eq i32 %116, 43
br i1 %117, label %118, label %119
118: ; preds = %108
store i32 1, i32* %10
br label %120
119: ; preds = %108, %104
store i32 0, i32* %10
br label %120
120: ; preds = %119, %118
%121 = load i32, i32* %7
%122 = icmp eq i32 %121, 0
br i1 %122, label %123, label %133
123: ; preds = %120
%124 = load i32, i32* %8
%125 = icmp eq i32 %124, 0
br i1 %125, label %126, label %133
126: ; preds = %123
%127 = load i32, i32* %9
%128 = icmp eq i32 %127, 0
br i1 %128, label %129, label %133
129: ; preds = %126
%130 = load i32, i32* %10
%131 = icmp eq i32 %130, 0
br i1 %131, label %132, label %133
132: ; preds = %129
br label %188
133: ; preds = %129, %126, %123, %120
br label %134
134: ; preds = %186, %133
%135 = load i32, i32* %7
%136 = icmp eq i32 %135, 1
br i1 %136, label %146, label %137
137: ; preds = %134
%138 = load i32, i32* %8
%139 = icmp eq i32 %138, 1
br i1 %139, label %146, label %140
140: ; preds = %137
%141 = load i32, i32* %9
%142 = icmp eq i32 %141, 1
br i1 %142, label %146, label %143
143: ; preds = %140
%144 = load i32, i32* %10
%145 = icmp eq i32 %144, 1
br label %146
146: ; preds = %143, %140, %137, %134
%147 = phi i1 [ true, %140 ], [ true, %137 ], [ true, %134 ], [ %145, %143 ]
br i1 %147, label %148, label %187
148: ; preds = %146
%149 = call i32 (...) @rand()
%150 = srem i32 %149, 4
store i32 %150, i32* %6
%151 = load i32, i32* %6
%152 = icmp eq i32 %151, 0
br i1 %152, label %153, label %159
153: ; preds = %148
%154 = load i32, i32* %7
%155 = icmp eq i32 %154, 1
br i1 %155, label %156, label %159
156: ; preds = %153
%157 = load i32, i32* %4
%158 = sub nsw i32 %157, 1
store i32 %158, i32* %4
br label %187
159: ; preds = %153, %148
%160 = load i32, i32* %6
%161 = icmp eq i32 %160, 1
br i1 %161, label %162, label %168
162: ; preds = %159
%163 = load i32, i32* %8
%164 = icmp eq i32 %163, 1
br i1 %164, label %165, label %168
165: ; preds = %162
%166 = load i32, i32* %4
%167 = add nsw i32 %166, 1
store i32 %167, i32* %4
br label %187
168: ; preds = %162, %159
%169 = load i32, i32* %6
%170 = icmp eq i32 %169, 2
br i1 %170, label %171, label %177
171: ; preds = %168
%172 = load i32, i32* %9
%173 = icmp eq i32 %172, 1
br i1 %173, label %174, label %177
174: ; preds = %171
%175 = load i32, i32* %3
%176 = sub nsw i32 %175, 1
store i32 %176, i32* %3
br label %187
177: ; preds = %171, %168
%178 = load i32, i32* %6
%179 = icmp eq i32 %178, 3
br i1 %179, label %180, label %186
180: ; preds = %177
%181 = load i32, i32* %10
%182 = icmp eq i32 %181, 1
br i1 %182, label %183, label %186
183: ; preds = %180
%184 = load i32, i32* %3
%185 = add nsw i32 %184, 1
store i32 %185, i32* %3
br label %187
186: ; preds = %180, %177
br label %134
187: ; preds = %183, %174, %165, %156, %146
br label %44
188: ; preds = %132, %44
store i32 0, i32* %13
br label %189
189: ; preds = %211, %188
%190 = load i32, i32* %13
%191 = icmp slt i32 %190, 10
br i1 %191, label %192, label %214
192: ; preds = %189
%193 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i32 0, i32* %14
br label %194
194: ; preds = %206, %192
%195 = load i32, i32* %14
%196 = icmp slt i32 %195, 10
br i1 %196, label %197, label %209
197: ; preds = %194
%198 = load i32, i32* %13
%199 = sext i32 %198 to i64
%200 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %2, i64 0, i64 %199
%201 = load i32, i32* %14
%202 = sext i32 %201 to i64
%203 = getelementptr inbounds [10 x i32], [10 x i32]* %200, i64 0, i64 %202
%204 = load i32, i32* %203
%205 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %204)
br label %206
206: ; preds = %197
%207 = load i32, i32* %14
%208 = add nsw i32 %207, 1
store i32 %208, i32* %14
br label %194
209: ; preds = %194
%210 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %211
211: ; preds = %209
%212 = load i32, i32* %13
%213 = add nsw i32 %212, 1
store i32 %213, i32* %13
br label %189
214: ; preds = %189
ret i32 0
}

LLVM IR (-O2):
@.str.1 = [4 x i8] c"%c \00"
define i32 @main() {
%1 = alloca [10 x [10 x i32]]
%2 = tail call i64 @time(i32* null)
%3 = trunc i64 %2 to i32
%4 = tail call i32 @srand(i32 %3)
%5 = bitcast [10 x [10 x i32]]* %1 to i8*
%6 = tail call i32 (...) @rand()
%7 = tail call i32 (...) @rand()
%8 = bitcast [10 x [10 x i32]]* %1 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %8
%9 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 0, i64 4
%10 = bitcast i32* %9 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %10
%11 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 0, i64 8
store i32 43, i32* %11
%12 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 0, i64 9
store i32 43, i32* %12
%13 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 1, i64 0
%14 = bitcast i32* %13 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %14
%15 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 1, i64 4
%16 = bitcast i32* %15 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %16
%17 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 1, i64 8
store i32 43, i32* %17
%18 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 1, i64 9
store i32 43, i32* %18
%19 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 2, i64 0
%20 = bitcast i32* %19 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %20
%21 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 2, i64 4
%22 = bitcast i32* %21 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %22
%23 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 2, i64 8
store i32 43, i32* %23
%24 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 2, i64 9
store i32 43, i32* %24
%25 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 3, i64 0
%26 = bitcast i32* %25 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %26
%27 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 3, i64 4
%28 = bitcast i32* %27 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %28
%29 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 3, i64 8
store i32 43, i32* %29
%30 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 3, i64 9
store i32 43, i32* %30
%31 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 4, i64 0
%32 = bitcast i32* %31 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %32
%33 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 4, i64 4
%34 = bitcast i32* %33 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %34
%35 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 4, i64 8
store i32 43, i32* %35
%36 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 4, i64 9
store i32 43, i32* %36
%37 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 5, i64 0
%38 = bitcast i32* %37 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %38
%39 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 5, i64 4
%40 = bitcast i32* %39 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %40
%41 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 5, i64 8
store i32 43, i32* %41
%42 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 5, i64 9
store i32 43, i32* %42
%43 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 6, i64 0
%44 = bitcast i32* %43 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %44
%45 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 6, i64 4
%46 = bitcast i32* %45 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %46
%47 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 6, i64 8
store i32 43, i32* %47
%48 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 6, i64 9
store i32 43, i32* %48
%49 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 7, i64 0
%50 = bitcast i32* %49 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %50
%51 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 7, i64 4
%52 = bitcast i32* %51 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %52
%53 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 7, i64 8
store i32 43, i32* %53
%54 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 7, i64 9
store i32 43, i32* %54
%55 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 8, i64 0
%56 = bitcast i32* %55 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %56
%57 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 8, i64 4
%58 = bitcast i32* %57 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %58
%59 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 8, i64 8
store i32 43, i32* %59
%60 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 8, i64 9
store i32 43, i32* %60
%61 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 9, i64 0
%62 = bitcast i32* %61 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %62
%63 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 9, i64 4
%64 = bitcast i32* %63 to <4 x i32>*
store <4 x i32> <i32 43, i32 43, i32 43, i32 43>, <4 x i32>* %64
%65 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 9, i64 8
store i32 43, i32* %65
%66 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 9, i64 9
store i32 43, i32* %66
%67 = srem i32 %6, 10
%68 = srem i32 %7, 10
br label %69
69: ; preds = %0, %146
%70 = phi i32 [ %76, %146 ], [ 65, %0 ]
%71 = phi i32 [ %148, %146 ], [ %68, %0 ]
%72 = phi i32 [ %147, %146 ], [ %67, %0 ]
%73 = sext i32 %72 to i64
%74 = sext i32 %71 to i64
%75 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %73, i64 %74
store i32 %70, i32* %75
%76 = add nuw nsw i32 %70, 1
%77 = add nsw i32 %71, -1
%78 = icmp sgt i32 %71, 0
br i1 %78, label %79, label %84
79: ; preds = %69
%80 = zext i32 %77 to i64
%81 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %73, i64 %80
%82 = load i32, i32* %81
%83 = icmp eq i32 %82, 43
br i1 %83, label %85, label %84
84: ; preds = %79, %69
br label %85
85: ; preds = %79, %84
%86 = phi i1 [ true, %84 ], [ false, %79 ]
%87 = phi i1 [ false, %84 ], [ true, %79 ]
%88 = add nsw i32 %71, 1
%89 = icmp slt i32 %71, 9
br i1 %89, label %90, label %95
90: ; preds = %85
%91 = sext i32 %88 to i64
%92 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %73, i64 %91
%93 = load i32, i32* %92
%94 = icmp eq i32 %93, 43
br i1 %94, label %96, label %95
95: ; preds = %90, %85
br label %96
96: ; preds = %90, %95
%97 = phi i1 [ true, %95 ], [ false, %90 ]
%98 = phi i1 [ false, %95 ], [ true, %90 ]
%99 = add nsw i32 %72, -1
%100 = icmp sgt i32 %72, 0
br i1 %100, label %101, label %108
101: ; preds = %96
%102 = zext i32 %99 to i64
%103 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %102, i64 %74
%104 = load i32, i32* %103
%105 = icmp eq i32 %104, 43
%106 = add nuw nsw i32 %72, 1
%107 = xor i1 %105, true
br label %111
108: ; preds = %96
%109 = add nsw i32 %72, 1
%110 = icmp sgt i32 %72, -2
br i1 %110, label %111, label %119
111: ; preds = %101, %108
%112 = phi i32 [ %109, %108 ], [ %106, %101 ]
%113 = phi i1 [ false, %108 ], [ %105, %101 ]
%114 = phi i1 [ true, %108 ], [ %107, %101 ]
%115 = zext i32 %112 to i64
%116 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %115, i64 %74
%117 = load i32, i32* %116
%118 = icmp eq i32 %117, 43
br i1 %118, label %128, label %119
119: ; preds = %108, %111
%120 = phi i32 [ %112, %111 ], [ %109, %108 ]
%121 = phi i1 [ %113, %111 ], [ false, %108 ]
%122 = phi i1 [ %114, %111 ], [ true, %108 ]
%123 = and i1 %86, %97
%124 = and i1 %123, %122
br i1 %124, label %150, label %125
125: ; preds = %119
%126 = or i1 %87, %98
%127 = or i1 %126, %121
br i1 %127, label %128, label %146
128: ; preds = %111, %125
%129 = phi i32 [ %120, %125 ], [ %112, %111 ]
%130 = phi i1 [ %121, %125 ], [ %113, %111 ]
%131 = phi i1 [ false, %125 ], [ true, %111 ]
br label %132
132: ; preds = %128, %143
%133 = tail call i32 (...) @rand()
%134 = srem i32 %133, 4
%135 = icmp eq i32 %134, 0
%136 = and i1 %87, %135
br i1 %136, label %146, label %137
137: ; preds = %132
%138 = icmp eq i32 %134, 1
%139 = and i1 %98, %138
br i1 %139, label %146, label %140
140: ; preds = %137
%141 = icmp eq i32 %134, 2
%142 = and i1 %130, %141
br i1 %142, label %146, label %143
143: ; preds = %140
%144 = icmp eq i32 %134, 3
%145 = and i1 %131, %144
br i1 %145, label %146, label %132
146: ; preds = %132, %137, %140, %143, %125
%147 = phi i32 [ %72, %125 ], [ %72, %132 ], [ %72, %137 ], [ %99, %140 ], [ %129, %143 ]
%148 = phi i32 [ %71, %125 ], [ %77, %132 ], [ %88, %137 ], [ %71, %140 ], [ %71, %143 ]
%149 = icmp eq i32 %76, 91
br i1 %149, label %150, label %69
150: ; preds = %119, %146
br label %152
151: ; preds = %152
ret i32 0
152: ; preds = %150, %152
%153 = phi i64 [ %186, %152 ], [ 0, %150 ]
%154 = tail call i32 @putchar(i32 9)
%155 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 0
%156 = load i32, i32* %155
%157 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %156)
%158 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 1
%159 = load i32, i32* %158
%160 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %159)
%161 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 2
%162 = load i32, i32* %161
%163 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %162)
%164 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 3
%165 = load i32, i32* %164
%166 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %165)
%167 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 4
%168 = load i32, i32* %167
%169 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %168)
%170 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 5
%171 = load i32, i32* %170
%172 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %171)
%173 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 6
%174 = load i32, i32* %173
%175 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %174)
%176 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 7
%177 = load i32, i32* %176
%178 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %177)
%179 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 8
%180 = load i32, i32* %179
%181 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %180)
%182 = getelementptr inbounds [10 x [10 x i32]], [10 x [10 x i32]]* %1, i64 0, i64 %153, i64 9
%183 = load i32, i32* %182
%184 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %183)
%185 = tail call i32 @putchar(i32 10)
%186 = add nuw nsw i64 %153, 1
%187 = icmp eq i64 %186, 10
br i1 %187, label %151, label %152
}