#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 */
char getch();
int /*<<< orphan*/ printf(char *);
int rand();
int /*<<< orphan*/ sleep(int);
int /*<<< orphan*/ srand(int /*<<< orphan*/);
int /*<<< orphan*/ system(char *);
int /*<<< orphan*/ time(int /*<<< orphan*/);
int main() {
  int mapa[15][15] = {
      {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1},
      {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1},
  };
  int i, j, x, fp, cp, fp2, cp2;
  int band, dir, tiempo;
  char tecla, tecla2;
  printf("\n\t\t   PERSEGUIR");
  fp = 1;
  cp = 1;
  mapa[fp][cp] = 10;
  fp2 = 13;
  cp2 = 13;
  mapa[fp2][cp2] = 2;
  tecla = 0;
  tecla2 = 0;
  srand(time(0));
  dir = rand() % 4 + 1;
  tiempo = 0;
  for (i = 0; i < 15; i++) {
    printf("\n\t\t");
    for (j = 0; j < 15; j++) {
      if (mapa[i][j] == 0) {
        printf(" ");
      }
      if (mapa[i][j] == 1) {
        printf("@");
      }
      if (mapa[i][j] == 10) {
        printf("\1");
      }
      if (mapa[i][j] == 2) {
        printf("\2");
      }
    }
  }
  while (tecla != 's' || tecla != 'S') {
    tecla = 0;
    tecla = getch();
    mapa[fp][cp] = 0;
    if (tecla == 77) {
      if (mapa[fp][cp + 1] == 0) {
        cp++;
      }
    }
    if (tecla == 75) {
      if (mapa[fp][cp - 1] == 0) {
        cp--;
      }
    }
    if (tecla == 80) {
      if (mapa[fp + 1][cp] == 0) {
        fp++;
      }
    }
    if (tecla == 72) {
      if (mapa[fp - 1][cp] == 0) {
        fp--;
      }
    }
    mapa[fp][cp] = 10;
    if (mapa[fp][cp] != mapa[1][1]) {
      mapa[fp2][cp2] = 0;
      if (dir == 1) {
        if (mapa[fp2][cp2 + 1] == 0) {
          cp2++;
        }
      }
      if (dir == 2) {
        if (mapa[fp2][cp2 - 1] == 0) {
          cp2--;
        }
      }
      if (dir == 3) {
        if (mapa[fp2 + 1][cp2] == 0) {
          fp2++;
        }
      }
      if (dir == 4) {
        if (mapa[fp2 - 1][cp2] == 0) {
          fp2--;
        }
      }
      mapa[fp2][cp2] = 2;
      tiempo++;
      if (tiempo % 5 == 0) {
        dir = rand() % 4 + 1;
      }
      sleep(100);
    }
    system("CLS");
    for (i = 0; i < 15; i++) {
      printf("\n\t\t");
      for (j = 0; j < 15; j++) {
        if (mapa[i][j] == 0) {
          printf(" ");
        }
        if (mapa[i][j] == 1) {
          printf("@");
        }
        if (mapa[i][j] == 10) {
          printf("\1");
        }
        if (mapa[i][j] == 2) {
          printf("\2");
        }
      }
    }
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x3c0,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x390(%rbp),%rdi
lea    0xe60(%rip),%rsi
mov    $0x384,%edx
call   1060 <memcpy@plt>
lea    0x11d3(%rip),%rdi
call   1040 <printf@plt>
movl   $0x1,-0x3a0(%rbp)
movl   $0x1,-0x3a4(%rbp)
movslq -0x3a0(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3a4(%rbp),%rcx
movl   $0xa,(%rax,%rcx,4)
movl   $0xd,-0x3a8(%rbp)
movl   $0xd,-0x3ac(%rbp)
movslq -0x3a8(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3ac(%rbp),%rcx
movl   $0x2,(%rax,%rcx,4)
movb   $0x0,-0x3b9(%rbp)
movb   $0x0,-0x3ba(%rbp)
xor    %edi,%edi
call   1070 <time@plt>
mov    %eax,%edi
call   1050 <srand@plt>
mov    $0x0,%al
call   10a0 <rand@plt>
mov    $0x4,%ecx
cltd
idiv   %ecx
add    $0x1,%edx
mov    %edx,-0x3b4(%rbp)
movl   $0x0,-0x3b8(%rbp)
movl   $0x0,-0x394(%rbp)
cmpl   $0xf,-0x394(%rbp)
jge    1396 <main+0x216>
lea    0x1114(%rip),%rdi
call   1040 <printf@plt>
movl   $0x0,-0x398(%rbp)
cmpl   $0xf,-0x398(%rbp)
jge    137d <main+0x1fd>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    12ce <main+0x14e>
lea    0x10cf(%rip),%rdi
call   1040 <printf@plt>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0x1,(%rax,%rcx,4)
jne    1300 <main+0x180>
lea    0x109f(%rip),%rdi
call   1040 <printf@plt>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0xa,(%rax,%rcx,4)
jne    1332 <main+0x1b2>
lea    0x106f(%rip),%rdi
call   1040 <printf@plt>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0x2,(%rax,%rcx,4)
jne    1364 <main+0x1e4>
lea    0x103f(%rip),%rdi
call   1040 <printf@plt>
jmp    1369 <main+0x1e9>
mov    -0x398(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x398(%rbp)
jmp    128f <main+0x10f>
jmp    1382 <main+0x202>
mov    -0x394(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x394(%rbp)
jmp    126c <main+0xec>
jmp    139b <main+0x21b>
movsbl -0x3b9(%rbp),%ecx
mov    $0x1,%al
cmp    $0x73,%ecx
mov    %al,-0x3bb(%rbp)
jne    13c6 <main+0x246>
movsbl -0x3b9(%rbp),%eax
cmp    $0x53,%eax
setne  %al
mov    %al,-0x3bb(%rbp)
mov    -0x3bb(%rbp),%al
test   $0x1,%al
jne    13d9 <main+0x259>
jmp    189d <main+0x71d>
movb   $0x0,-0x3b9(%rbp)
mov    $0x0,%al
call   1080 <getch@plt>
mov    %al,-0x3b9(%rbp)
movslq -0x3a0(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3a4(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
movsbl -0x3b9(%rbp),%eax
cmp    $0x4d,%eax
jne    145f <main+0x2df>
movslq -0x3a0(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
mov    -0x3a4(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    145a <main+0x2da>
mov    -0x3a4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3a4(%rbp)
jmp    145f <main+0x2df>
movsbl -0x3b9(%rbp),%eax
cmp    $0x4b,%eax
jne    14ae <main+0x32e>
movslq -0x3a0(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
mov    -0x3a4(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    14a9 <main+0x329>
mov    -0x3a4(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x3a4(%rbp)
jmp    14ae <main+0x32e>
movsbl -0x3b9(%rbp),%eax
cmp    $0x50,%eax
jne    14fd <main+0x37d>
mov    -0x3a0(%rbp),%eax
add    $0x1,%eax
movslq %eax,%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3a4(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    14f8 <main+0x378>
mov    -0x3a0(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3a0(%rbp)
jmp    14fd <main+0x37d>
movsbl -0x3b9(%rbp),%eax
cmp    $0x48,%eax
jne    154c <main+0x3cc>
mov    -0x3a0(%rbp),%eax
sub    $0x1,%eax
movslq %eax,%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3a4(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    1547 <main+0x3c7>
mov    -0x3a0(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x3a0(%rbp)
jmp    154c <main+0x3cc>
movslq -0x3a0(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3a4(%rbp),%rcx
movl   $0xa,(%rax,%rcx,4)
movslq -0x3a0(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3a4(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
cmp    -0x350(%rbp),%eax
je     1758 <main+0x5d8>
movslq -0x3a8(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3ac(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
cmpl   $0x1,-0x3b4(%rbp)
jne    1609 <main+0x489>
movslq -0x3a8(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
mov    -0x3ac(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    1604 <main+0x484>
mov    -0x3ac(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3ac(%rbp)
jmp    1609 <main+0x489>
cmpl   $0x2,-0x3b4(%rbp)
jne    1655 <main+0x4d5>
movslq -0x3a8(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
mov    -0x3ac(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    1650 <main+0x4d0>
mov    -0x3ac(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x3ac(%rbp)
jmp    1655 <main+0x4d5>
cmpl   $0x3,-0x3b4(%rbp)
jne    16a1 <main+0x521>
mov    -0x3a8(%rbp),%eax
add    $0x1,%eax
movslq %eax,%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3ac(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    169c <main+0x51c>
mov    -0x3a8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3a8(%rbp)
jmp    16a1 <main+0x521>
cmpl   $0x4,-0x3b4(%rbp)
jne    16ed <main+0x56d>
mov    -0x3a8(%rbp),%eax
sub    $0x1,%eax
movslq %eax,%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3ac(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    16e8 <main+0x568>
mov    -0x3a8(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x3a8(%rbp)
jmp    16ed <main+0x56d>
movslq -0x3a8(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x3ac(%rbp),%rcx
movl   $0x2,(%rax,%rcx,4)
mov    -0x3b8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3b8(%rbp)
mov    -0x3b8(%rbp),%eax
mov    $0x5,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jne    174e <main+0x5ce>
mov    $0x0,%al
call   10a0 <rand@plt>
mov    $0x4,%ecx
cltd
idiv   %ecx
add    $0x1,%edx
mov    %edx,-0x3b4(%rbp)
mov    $0x64,%edi
call   1090 <sleep@plt>
lea    0xc41(%rip),%rdi
call   1030 <system@plt>
movl   $0x0,-0x394(%rbp)
cmpl   $0xf,-0x394(%rbp)
jge    1898 <main+0x718>
lea    0xc12(%rip),%rdi
call   1040 <printf@plt>
movl   $0x0,-0x398(%rbp)
cmpl   $0xf,-0x398(%rbp)
jge    187f <main+0x6ff>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    17d0 <main+0x650>
lea    0xbcd(%rip),%rdi
call   1040 <printf@plt>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0x1,(%rax,%rcx,4)
jne    1802 <main+0x682>
lea    0xb9d(%rip),%rdi
call   1040 <printf@plt>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0xa,(%rax,%rcx,4)
jne    1834 <main+0x6b4>
lea    0xb6d(%rip),%rdi
call   1040 <printf@plt>
movslq -0x394(%rbp),%rcx
lea    -0x390(%rbp),%rax
imul   $0x3c,%rcx,%rcx
add    %rcx,%rax
movslq -0x398(%rbp),%rcx
cmpl   $0x2,(%rax,%rcx,4)
jne    1866 <main+0x6e6>
lea    0xb3d(%rip),%rdi
call   1040 <printf@plt>
jmp    186b <main+0x6eb>
mov    -0x398(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x398(%rbp)
jmp    1791 <main+0x611>
jmp    1884 <main+0x704>
mov    -0x394(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x394(%rbp)
jmp    176e <main+0x5ee>
jmp    139b <main+0x21b>
mov    -0x4(%rbp),%eax
add    $0x3c0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x3a8,%rsp
lea    0xee8(%rip),%rsi
lea    0x20(%rsp),%r12
mov    $0x384,%edx
mov    %r12,%rdi
call   1070 <memcpy@plt>
lea    0x1253(%rip),%rdi
call   1050 <printf@plt>
movl   $0xa,0x60(%rsp)
movl   $0x2,0x360(%rsp)
xor    %r15d,%r15d
xor    %edi,%edi
call   1080 <time@plt>
mov    %eax,%edi
call   1060 <srand@plt>
xor    %eax,%eax
call   10b0 <rand@plt>
lea    0x3(%rax),%ecx
test   %eax,%eax
cmovns %eax,%ecx
and    $0xfffffffc,%ecx
sub    %ecx,%eax
mov    %rax,0x8(%rsp)
lea    0x121a(%rip),%r14
lea    0xdef(%rip),%rbp
jmp    122e <main+0x9e>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
add    $0x1,%r15
add    $0x3c,%r12
cmp    $0xf,%r15
je     1287 <main+0xf7>
mov    %r14,%rdi
call   1050 <printf@plt>
xor    %ebx,%ebx
jmp    1254 <main+0xc4>
nopw   0x0(%rax,%rax,1)
mov    $0x2,%edi
call   1030 <putchar@plt>
add    $0x1,%rbx
cmp    $0xf,%rbx
je     1220 <main+0x90>
mov    (%r12,%rbx,4),%eax
cmp    $0xa,%rax
ja     124a <main+0xba>
mov    $0x20,%edi
movslq 0x0(%rbp,%rax,4),%rax
add    %rbp,%rax
jmp    *%rax
mov    $0x40,%edi
jmp    1245 <main+0xb5>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    $0x1,%edi
jmp    1245 <main+0xb5>
mov    0x8(%rsp),%rax
add    $0x1,%eax
mov    %rax,0x8(%rsp)
mov    $0xd,%r14d
mov    $0x1,%r15d
lea    0x117d(%rip),%rbx
lea    0xdb2(%rip),%rbp
mov    $0x1,%r12d
mov    $0xd,%r13d
movl   $0x0,(%rsp)
jmp    12e2 <main+0x152>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    %r12,%r14
mov    0x18(%rsp),%r15
mov    0x14(%rsp),%r12d
mov    0x4(%rsp),%r13d
xor    %eax,%eax
call   1090 <getch@plt>
movslq %r15d,%rdx
movslq %r12d,%rcx
imul   $0x3c,%rdx,%rdx
add    %rsp,%rdx
add    $0x20,%rdx
movl   $0x0,(%rdx,%rcx,4)
add    $0xb8,%al
cmp    $0x8,%al
ja     135c <main+0x1cc>
movzbl %al,%eax
lea    0xd1b(%rip),%rsi
movslq (%rsi,%rax,4),%rax
add    %rsi,%rax
jmp    *%rax
lea    -0x1(%r15),%eax
jmp    1344 <main+0x1b4>
lea    -0x1(%rcx),%r12d
cmpl   $0x0,-0x4(%rdx,%rcx,4)
cmovne %ecx,%r12d
jmp    135c <main+0x1cc>
nop
lea    0x1(%rcx),%r12d
cmpl   $0x0,0x4(%rdx,%rcx,4)
cmovne %ecx,%r12d
jmp    135c <main+0x1cc>
nop
lea    0x1(%r15),%eax
cltq
imul   $0x3c,%rax,%rdx
add    %rsp,%rdx
add    $0x20,%rdx
cmpl   $0x0,(%rdx,%rcx,4)
cmovne %r15d,%eax
mov    %eax,%r15d
movslq %r15d,%rax
movslq %r12d,%rcx
imul   $0x3c,%rax,%rax
add    %rsp,%rax
add    $0x20,%rax
movl   $0xa,(%rax,%rcx,4)
cmpl   $0xa,0x60(%rsp)
mov    %r15,0x18(%rsp)
mov    %r12d,0x14(%rsp)
jne    13a0 <main+0x210>
mov    %r13d,0x4(%rsp)
mov    %r14,%r12
jmp    1479 <main+0x2e9>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
movslq %r14d,%rcx
movslq %r13d,%rax
imul   $0x3c,%rcx,%rcx
add    %rsp,%rcx
add    $0x20,%rcx
movl   $0x0,(%rcx,%rax,4)
mov    0x8(%rsp),%rdx
add    $0xffffffff,%edx
cmp    $0x3,%edx
ja     1416 <main+0x286>
lea    0xc84(%rip),%rsi
movslq (%rsi,%rdx,4),%rdx
add    %rsi,%rdx
jmp    *%rdx
lea    0x1(%rax),%r13d
cmpl   $0x0,0x4(%rcx,%rax,4)
cmovne %eax,%r13d
jmp    1416 <main+0x286>
lea    -0x1(%rax),%r13d
cmpl   $0x0,-0x4(%rcx,%rax,4)
cmovne %eax,%r13d
jmp    1416 <main+0x286>
lea    0x1(%r14),%ecx
jmp    13fd <main+0x26d>
lea    -0x1(%r14),%ecx
movslq %ecx,%rcx
imul   $0x3c,%rcx,%rdx
add    %rsp,%rdx
add    $0x20,%rdx
cmpl   $0x0,(%rdx,%rax,4)
cmovne %r14d,%ecx
mov    %ecx,%r14d
mov    (%rsp),%edx
movslq %r14d,%rax
movslq %r13d,%rcx
imul   $0x3c,%rax,%rax
add    %rsp,%rax
add    $0x20,%rax
movl   $0x2,(%rax,%rcx,4)
add    $0x1,%edx
mov    %edx,(%rsp)
imul   $0xcccccccd,%edx,%eax
add    $0x19999999,%eax
cmp    $0x33333332,%eax
ja     1467 <main+0x2d7>
xor    %eax,%eax
call   10b0 <rand@plt>
lea    0x3(%rax),%ecx
test   %eax,%eax
cmovns %eax,%ecx
and    $0xfffffffc,%ecx
neg    %ecx
add    %ecx,%eax
add    $0x1,%eax
mov    %rax,0x8(%rsp)
mov    %r13d,0x4(%rsp)
mov    %r14,%r12
mov    $0x64,%edi
call   10a0 <sleep@plt>
lea    0xfa8(%rip),%rdi
call   1040 <system@plt>
lea    0x20(%rsp),%r13
xor    %r15d,%r15d
jmp    14a2 <main+0x312>
nop
add    $0x1,%r15
add    $0x3c,%r13
cmp    $0xf,%r15
je     12d0 <main+0x140>
mov    %rbx,%rdi
call   1050 <printf@plt>
xor    %r14d,%r14d
jmp    14c4 <main+0x334>
nop
mov    $0x2,%edi
call   1030 <putchar@plt>
add    $0x1,%r14
cmp    $0xf,%r14
je     1490 <main+0x300>
mov    0x0(%r13,%r14,4),%eax
cmp    $0xa,%rax
ja     14ba <main+0x32a>
mov    $0x20,%edi
movslq 0x0(%rbp,%rax,4),%rax
add    %rbp,%rax
jmp    *%rax
mov    $0x40,%edi
jmp    14b5 <main+0x325>
cs nopw 0x0(%rax,%rax,1)
nop
mov    $0x1,%edi
jmp    14b5 <main+0x325>

LLVM IR (-O0):
@__const.main.mapa = [15 x [15 x i32]] [[15 x i32] [i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1]]
@.str = [16 x i8] c"\0A\09\09 PERSEGUIR\00"
@.str.1 = [4 x i8] c"\0A\09\09\00"
@.str.2 = [2 x i8] c" \00"
@.str.3 = [2 x i8] c"@\00"
@.str.4 = [2 x i8] c"\01\00"
@.str.5 = [2 x i8] c"\02\00"
@.str.6 = [4 x i8] c"CLS\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [15 x [15 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 i8
%14 = alloca i8
store i32 0, i32* %1
%15 = bitcast [15 x [15 x i32]]* %2 to i8*
%16 = call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %6
store i32 1, i32* %7
%17 = load i32, i32* %6
%18 = sext i32 %17 to i64
%19 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %18
%20 = load i32, i32* %7
%21 = sext i32 %20 to i64
%22 = getelementptr inbounds [15 x i32], [15 x i32]* %19, i64 0, i64 %21
store i32 10, i32* %22
store i32 13, i32* %8
store i32 13, i32* %9
%23 = load i32, i32* %8
%24 = sext i32 %23 to i64
%25 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %24
%26 = load i32, i32* %9
%27 = sext i32 %26 to i64
%28 = getelementptr inbounds [15 x i32], [15 x i32]* %25, i64 0, i64 %27
store i32 2, i32* %28
store i8 0, i8* %13
store i8 0, i8* %14
%29 = call i32 @time(i32 0)
%30 = call i32 @srand(i32 %29)
%31 = call i32 (...) @rand()
%32 = srem i32 %31, 4
%33 = add nsw i32 %32, 1
store i32 %33, i32* %11
store i32 0, i32* %12
store i32 0, i32* %3
br label %34
34: ; preds = %91, %0
%35 = load i32, i32* %3
%36 = icmp slt i32 %35, 15
br i1 %36, label %37, label %94
37: ; preds = %34
%38 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
store i32 0, i32* %4
br label %39
39: ; preds = %87, %37
%40 = load i32, i32* %4
%41 = icmp slt i32 %40, 15
br i1 %41, label %42, label %90
42: ; preds = %39
%43 = load i32, i32* %3
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %44
%46 = load i32, i32* %4
%47 = sext i32 %46 to i64
%48 = getelementptr inbounds [15 x i32], [15 x i32]* %45, i64 0, i64 %47
%49 = load i32, i32* %48
%50 = icmp eq i32 %49, 0
br i1 %50, label %51, label %53
51: ; preds = %42
%52 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %53
53: ; preds = %51, %42
%54 = load i32, i32* %3
%55 = sext i32 %54 to i64
%56 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %55
%57 = load i32, i32* %4
%58 = sext i32 %57 to i64
%59 = getelementptr inbounds [15 x i32], [15 x i32]* %56, i64 0, i64 %58
%60 = load i32, i32* %59
%61 = icmp eq i32 %60, 1
br i1 %61, label %62, label %64
62: ; preds = %53
%63 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
br label %64
64: ; preds = %62, %53
%65 = load i32, i32* %3
%66 = sext i32 %65 to i64
%67 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %66
%68 = load i32, i32* %4
%69 = sext i32 %68 to i64
%70 = getelementptr inbounds [15 x i32], [15 x i32]* %67, i64 0, i64 %69
%71 = load i32, i32* %70
%72 = icmp eq i32 %71, 10
br i1 %72, label %73, label %75
73: ; preds = %64
%74 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
br label %75
75: ; preds = %73, %64
%76 = load i32, i32* %3
%77 = sext i32 %76 to i64
%78 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %77
%79 = load i32, i32* %4
%80 = sext i32 %79 to i64
%81 = getelementptr inbounds [15 x i32], [15 x i32]* %78, i64 0, i64 %80
%82 = load i32, i32* %81
%83 = icmp eq i32 %82, 2
br i1 %83, label %84, label %86
84: ; preds = %75
%85 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.5, i64 0, i64 0))
br label %86
86: ; preds = %84, %75
br label %87
87: ; preds = %86
%88 = load i32, i32* %4
%89 = add nsw i32 %88, 1
store i32 %89, i32* %4
br label %39
90: ; preds = %39
br label %91
91: ; preds = %90
%92 = load i32, i32* %3
%93 = add nsw i32 %92, 1
store i32 %93, i32* %3
br label %34
94: ; preds = %34
br label %95
95: ; preds = %356, %94
%96 = load i8, i8* %13
%97 = sext i8 %96 to i32
%98 = icmp ne i32 %97, 115
br i1 %98, label %103, label %99
99: ; preds = %95
%100 = load i8, i8* %13
%101 = sext i8 %100 to i32
%102 = icmp ne i32 %101, 83
br label %103
103: ; preds = %99, %95
%104 = phi i1 [ true, %95 ], [ %102, %99 ]
br i1 %104, label %105, label %357
105: ; preds = %103
store i8 0, i8* %13
%106 = call signext i8 (...) @getch()
store i8 %106, i8* %13
%107 = load i32, i32* %6
%108 = sext i32 %107 to i64
%109 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %108
%110 = load i32, i32* %7
%111 = sext i32 %110 to i64
%112 = getelementptr inbounds [15 x i32], [15 x i32]* %109, i64 0, i64 %111
store i32 0, i32* %112
%113 = load i8, i8* %13
%114 = sext i8 %113 to i32
%115 = icmp eq i32 %114, 77
br i1 %115, label %116, label %130
116: ; preds = %105
%117 = load i32, i32* %6
%118 = sext i32 %117 to i64
%119 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %118
%120 = load i32, i32* %7
%121 = add nsw i32 %120, 1
%122 = sext i32 %121 to i64
%123 = getelementptr inbounds [15 x i32], [15 x i32]* %119, i64 0, i64 %122
%124 = load i32, i32* %123
%125 = icmp eq i32 %124, 0
br i1 %125, label %126, label %129
126: ; preds = %116
%127 = load i32, i32* %7
%128 = add nsw i32 %127, 1
store i32 %128, i32* %7
br label %129
129: ; preds = %126, %116
br label %130
130: ; preds = %129, %105
%131 = load i8, i8* %13
%132 = sext i8 %131 to i32
%133 = icmp eq i32 %132, 75
br i1 %133, label %134, label %148
134: ; preds = %130
%135 = load i32, i32* %6
%136 = sext i32 %135 to i64
%137 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %136
%138 = load i32, i32* %7
%139 = sub nsw i32 %138, 1
%140 = sext i32 %139 to i64
%141 = getelementptr inbounds [15 x i32], [15 x i32]* %137, i64 0, i64 %140
%142 = load i32, i32* %141
%143 = icmp eq i32 %142, 0
br i1 %143, label %144, label %147
144: ; preds = %134
%145 = load i32, i32* %7
%146 = add nsw i32 %145, -1
store i32 %146, i32* %7
br label %147
147: ; preds = %144, %134
br label %148
148: ; preds = %147, %130
%149 = load i8, i8* %13
%150 = sext i8 %149 to i32
%151 = icmp eq i32 %150, 80
br i1 %151, label %152, label %166
152: ; preds = %148
%153 = load i32, i32* %6
%154 = add nsw i32 %153, 1
%155 = sext i32 %154 to i64
%156 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %155
%157 = load i32, i32* %7
%158 = sext i32 %157 to i64
%159 = getelementptr inbounds [15 x i32], [15 x i32]* %156, i64 0, i64 %158
%160 = load i32, i32* %159
%161 = icmp eq i32 %160, 0
br i1 %161, label %162, label %165
162: ; preds = %152
%163 = load i32, i32* %6
%164 = add nsw i32 %163, 1
store i32 %164, i32* %6
br label %165
165: ; preds = %162, %152
br label %166
166: ; preds = %165, %148
%167 = load i8, i8* %13
%168 = sext i8 %167 to i32
%169 = icmp eq i32 %168, 72
br i1 %169, label %170, label %184
170: ; preds = %166
%171 = load i32, i32* %6
%172 = sub nsw i32 %171, 1
%173 = sext i32 %172 to i64
%174 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %173
%175 = load i32, i32* %7
%176 = sext i32 %175 to i64
%177 = getelementptr inbounds [15 x i32], [15 x i32]* %174, i64 0, i64 %176
%178 = load i32, i32* %177
%179 = icmp eq i32 %178, 0
br i1 %179, label %180, label %183
180: ; preds = %170
%181 = load i32, i32* %6
%182 = add nsw i32 %181, -1
store i32 %182, i32* %6
br label %183
183: ; preds = %180, %170
br label %184
184: ; preds = %183, %166
%185 = load i32, i32* %6
%186 = sext i32 %185 to i64
%187 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %186
%188 = load i32, i32* %7
%189 = sext i32 %188 to i64
%190 = getelementptr inbounds [15 x i32], [15 x i32]* %187, i64 0, i64 %189
store i32 10, i32* %190
%191 = load i32, i32* %6
%192 = sext i32 %191 to i64
%193 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %192
%194 = load i32, i32* %7
%195 = sext i32 %194 to i64
%196 = getelementptr inbounds [15 x i32], [15 x i32]* %193, i64 0, i64 %195
%197 = load i32, i32* %196
%198 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 1
%199 = getelementptr inbounds [15 x i32], [15 x i32]* %198, i64 0, i64 1
%200 = load i32, i32* %199
%201 = icmp ne i32 %197, %200
br i1 %201, label %202, label %294
202: ; preds = %184
%203 = load i32, i32* %8
%204 = sext i32 %203 to i64
%205 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %204
%206 = load i32, i32* %9
%207 = sext i32 %206 to i64
%208 = getelementptr inbounds [15 x i32], [15 x i32]* %205, i64 0, i64 %207
store i32 0, i32* %208
%209 = load i32, i32* %11
%210 = icmp eq i32 %209, 1
br i1 %210, label %211, label %225
211: ; preds = %202
%212 = load i32, i32* %8
%213 = sext i32 %212 to i64
%214 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %213
%215 = load i32, i32* %9
%216 = add nsw i32 %215, 1
%217 = sext i32 %216 to i64
%218 = getelementptr inbounds [15 x i32], [15 x i32]* %214, i64 0, i64 %217
%219 = load i32, i32* %218
%220 = icmp eq i32 %219, 0
br i1 %220, label %221, label %224
221: ; preds = %211
%222 = load i32, i32* %9
%223 = add nsw i32 %222, 1
store i32 %223, i32* %9
br label %224
224: ; preds = %221, %211
br label %225
225: ; preds = %224, %202
%226 = load i32, i32* %11
%227 = icmp eq i32 %226, 2
br i1 %227, label %228, label %242
228: ; preds = %225
%229 = load i32, i32* %8
%230 = sext i32 %229 to i64
%231 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %230
%232 = load i32, i32* %9
%233 = sub nsw i32 %232, 1
%234 = sext i32 %233 to i64
%235 = getelementptr inbounds [15 x i32], [15 x i32]* %231, i64 0, i64 %234
%236 = load i32, i32* %235
%237 = icmp eq i32 %236, 0
br i1 %237, label %238, label %241
238: ; preds = %228
%239 = load i32, i32* %9
%240 = add nsw i32 %239, -1
store i32 %240, i32* %9
br label %241
241: ; preds = %238, %228
br label %242
242: ; preds = %241, %225
%243 = load i32, i32* %11
%244 = icmp eq i32 %243, 3
br i1 %244, label %245, label %259
245: ; preds = %242
%246 = load i32, i32* %8
%247 = add nsw i32 %246, 1
%248 = sext i32 %247 to i64
%249 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %248
%250 = load i32, i32* %9
%251 = sext i32 %250 to i64
%252 = getelementptr inbounds [15 x i32], [15 x i32]* %249, i64 0, i64 %251
%253 = load i32, i32* %252
%254 = icmp eq i32 %253, 0
br i1 %254, label %255, label %258
255: ; preds = %245
%256 = load i32, i32* %8
%257 = add nsw i32 %256, 1
store i32 %257, i32* %8
br label %258
258: ; preds = %255, %245
br label %259
259: ; preds = %258, %242
%260 = load i32, i32* %11
%261 = icmp eq i32 %260, 4
br i1 %261, label %262, label %276
262: ; preds = %259
%263 = load i32, i32* %8
%264 = sub nsw i32 %263, 1
%265 = sext i32 %264 to i64
%266 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %265
%267 = load i32, i32* %9
%268 = sext i32 %267 to i64
%269 = getelementptr inbounds [15 x i32], [15 x i32]* %266, i64 0, i64 %268
%270 = load i32, i32* %269
%271 = icmp eq i32 %270, 0
br i1 %271, label %272, label %275
272: ; preds = %262
%273 = load i32, i32* %8
%274 = add nsw i32 %273, -1
store i32 %274, i32* %8
br label %275
275: ; preds = %272, %262
br label %276
276: ; preds = %275, %259
%277 = load i32, i32* %8
%278 = sext i32 %277 to i64
%279 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %278
%280 = load i32, i32* %9
%281 = sext i32 %280 to i64
%282 = getelementptr inbounds [15 x i32], [15 x i32]* %279, i64 0, i64 %281
store i32 2, i32* %282
%283 = load i32, i32* %12
%284 = add nsw i32 %283, 1
store i32 %284, i32* %12
%285 = load i32, i32* %12
%286 = srem i32 %285, 5
%287 = icmp eq i32 %286, 0
br i1 %287, label %288, label %292
288: ; preds = %276
%289 = call i32 (...) @rand()
%290 = srem i32 %289, 4
%291 = add nsw i32 %290, 1
store i32 %291, i32* %11
br label %292
292: ; preds = %288, %276
%293 = call i32 @sleep(i32 100)
br label %294
294: ; preds = %292, %184
%295 = call i32 @system(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0))
store i32 0, i32* %3
br label %296
296: ; preds = %353, %294
%297 = load i32, i32* %3
%298 = icmp slt i32 %297, 15
br i1 %298, label %299, label %356
299: ; preds = %296
%300 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
store i32 0, i32* %4
br label %301
301: ; preds = %349, %299
%302 = load i32, i32* %4
%303 = icmp slt i32 %302, 15
br i1 %303, label %304, label %352
304: ; preds = %301
%305 = load i32, i32* %3
%306 = sext i32 %305 to i64
%307 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %306
%308 = load i32, i32* %4
%309 = sext i32 %308 to i64
%310 = getelementptr inbounds [15 x i32], [15 x i32]* %307, i64 0, i64 %309
%311 = load i32, i32* %310
%312 = icmp eq i32 %311, 0
br i1 %312, label %313, label %315
313: ; preds = %304
%314 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %315
315: ; preds = %313, %304
%316 = load i32, i32* %3
%317 = sext i32 %316 to i64
%318 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %317
%319 = load i32, i32* %4
%320 = sext i32 %319 to i64
%321 = getelementptr inbounds [15 x i32], [15 x i32]* %318, i64 0, i64 %320
%322 = load i32, i32* %321
%323 = icmp eq i32 %322, 1
br i1 %323, label %324, label %326
324: ; preds = %315
%325 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
br label %326
326: ; preds = %324, %315
%327 = load i32, i32* %3
%328 = sext i32 %327 to i64
%329 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %328
%330 = load i32, i32* %4
%331 = sext i32 %330 to i64
%332 = getelementptr inbounds [15 x i32], [15 x i32]* %329, i64 0, i64 %331
%333 = load i32, i32* %332
%334 = icmp eq i32 %333, 10
br i1 %334, label %335, label %337
335: ; preds = %326
%336 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
br label %337
337: ; preds = %335, %326
%338 = load i32, i32* %3
%339 = sext i32 %338 to i64
%340 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %2, i64 0, i64 %339
%341 = load i32, i32* %4
%342 = sext i32 %341 to i64
%343 = getelementptr inbounds [15 x i32], [15 x i32]* %340, i64 0, i64 %342
%344 = load i32, i32* %343
%345 = icmp eq i32 %344, 2
br i1 %345, label %346, label %348
346: ; preds = %337
%347 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.5, i64 0, i64 0))
br label %348
348: ; preds = %346, %337
br label %349
349: ; preds = %348
%350 = load i32, i32* %4
%351 = add nsw i32 %350, 1
store i32 %351, i32* %4
br label %301
352: ; preds = %301
br label %353
353: ; preds = %352
%354 = load i32, i32* %3
%355 = add nsw i32 %354, 1
store i32 %355, i32* %3
br label %296
356: ; preds = %296
br label %95
357: ; preds = %103
%358 = load i32, i32* %1
ret i32 %358
}

LLVM IR (-O2):
@__const.main.mapa = [15 x [15 x i32]] [[15 x i32] [i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 0, i32 1], [15 x i32] [i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1, i32 1]]
@.str = [16 x i8] c"\0A\09\09 PERSEGUIR\00"
@.str.1 = [4 x i8] c"\0A\09\09\00"
@.str.6 = [4 x i8] c"CLS\00"
define i32 @main() {
%1 = alloca [15 x [15 x i32]]
%2 = bitcast [15 x [15 x i32]]* %1 to i8*
%3 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
%4 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 1, i64 1
store i32 10, i32* %4
%5 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 13, i64 13
store i32 2, i32* %5
%6 = tail call i32 @time(i32 0)
%7 = tail call i32 @srand(i32 %6)
%8 = tail call i32 (...) @rand()
%9 = srem i32 %8, 4
br label %10
10: ; preds = %0, %26
%11 = phi i64 [ 0, %0 ], [ %27, %26 ]
%12 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
br label %13
13: ; preds = %10, %23
%14 = phi i64 [ 0, %10 ], [ %24, %23 ]
%15 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %11, i64 %14
%16 = load i32, i32* %15
switch i32 %16, label %23 [
i32 0, label %20
i32 1, label %17
i32 10, label %18
i32 2, label %19
]
17: ; preds = %13
br label %20
18: ; preds = %13
br label %20
19: ; preds = %13
br label %20
20: ; preds = %13, %19, %18, %17
%21 = phi i32 [ 64, %17 ], [ 1, %18 ], [ 2, %19 ], [ 32, %13 ]
%22 = tail call i32 @putchar(i32 %21)
br label %23
23: ; preds = %20, %13
%24 = add nuw nsw i64 %14, 1
%25 = icmp eq i64 %24, 15
br i1 %25, label %26, label %13
26: ; preds = %23
%27 = add nuw nsw i64 %11, 1
%28 = icmp eq i64 %27, 15
br i1 %28, label %29, label %10
29: ; preds = %26
%30 = add nsw i32 %9, 1
br label %31
31: ; preds = %148, %29
%32 = phi i32 [ 1, %29 ], [ %72, %148 ]
%33 = phi i32 [ 1, %29 ], [ %71, %148 ]
%34 = phi i32 [ 13, %29 ], [ %127, %148 ]
%35 = phi i32 [ 13, %29 ], [ %128, %148 ]
%36 = phi i32 [ %30, %29 ], [ %129, %148 ]
%37 = phi i32 [ 0, %29 ], [ %130, %148 ]
%38 = tail call signext i8 (...) @getch()
%39 = sext i32 %32 to i64
%40 = sext i32 %33 to i64
%41 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %39, i64 %40
store i32 0, i32* %41
switch i8 %38, label %70 [
i8 77, label %42
i8 75, label %49
i8 80, label %56
i8 72, label %63
]
42: ; preds = %31
%43 = add nsw i32 %33, 1
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %39, i64 %44
%46 = load i32, i32* %45
%47 = icmp eq i32 %46, 0
%48 = select i1 %47, i32 %43, i32 %33
br label %70
49: ; preds = %31
%50 = add nsw i32 %33, -1
%51 = sext i32 %50 to i64
%52 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %39, i64 %51
%53 = load i32, i32* %52
%54 = icmp eq i32 %53, 0
%55 = select i1 %54, i32 %50, i32 %33
br label %70
56: ; preds = %31
%57 = add nsw i32 %32, 1
%58 = sext i32 %57 to i64
%59 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %58, i64 %40
%60 = load i32, i32* %59
%61 = icmp eq i32 %60, 0
%62 = select i1 %61, i32 %57, i32 %32
br label %70
63: ; preds = %31
%64 = add nsw i32 %32, -1
%65 = sext i32 %64 to i64
%66 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %65, i64 %40
%67 = load i32, i32* %66
%68 = icmp eq i32 %67, 0
%69 = select i1 %68, i32 %64, i32 %32
br label %70
70: ; preds = %31, %49, %42, %56, %63
%71 = phi i32 [ %33, %63 ], [ %33, %56 ], [ %48, %42 ], [ %55, %49 ], [ %33, %31 ]
%72 = phi i32 [ %69, %63 ], [ %62, %56 ], [ %32, %42 ], [ %32, %49 ], [ %32, %31 ]
%73 = sext i32 %72 to i64
%74 = sext i32 %71 to i64
%75 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %73, i64 %74
store i32 10, i32* %75
%76 = load i32, i32* %4
%77 = icmp eq i32 %76, 10
br i1 %77, label %126, label %78
78: ; preds = %70
%79 = sext i32 %34 to i64
%80 = sext i32 %35 to i64
%81 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %79, i64 %80
store i32 0, i32* %81
switch i32 %36, label %110 [
i32 1, label %82
i32 2, label %89
i32 3, label %96
i32 4, label %103
]
82: ; preds = %78
%83 = add nsw i32 %35, 1
%84 = sext i32 %83 to i64
%85 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %79, i64 %84
%86 = load i32, i32* %85
%87 = icmp eq i32 %86, 0
%88 = select i1 %87, i32 %83, i32 %35
br label %110
89: ; preds = %78
%90 = add nsw i32 %35, -1
%91 = sext i32 %90 to i64
%92 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %79, i64 %91
%93 = load i32, i32* %92
%94 = icmp eq i32 %93, 0
%95 = select i1 %94, i32 %90, i32 %35
br label %110
96: ; preds = %78
%97 = add nsw i32 %34, 1
%98 = sext i32 %97 to i64
%99 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %98, i64 %80
%100 = load i32, i32* %99
%101 = icmp eq i32 %100, 0
%102 = select i1 %101, i32 %97, i32 %34
br label %110
103: ; preds = %78
%104 = add nsw i32 %34, -1
%105 = sext i32 %104 to i64
%106 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %105, i64 %80
%107 = load i32, i32* %106
%108 = icmp eq i32 %107, 0
%109 = select i1 %108, i32 %104, i32 %34
br label %110
110: ; preds = %78, %89, %82, %96, %103
%111 = phi i32 [ %35, %103 ], [ %35, %96 ], [ %88, %82 ], [ %95, %89 ], [ %35, %78 ]
%112 = phi i32 [ %109, %103 ], [ %102, %96 ], [ %34, %82 ], [ %34, %89 ], [ %34, %78 ]
%113 = sext i32 %112 to i64
%114 = sext i32 %111 to i64
%115 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %113, i64 %114
store i32 2, i32* %115
%116 = add nsw i32 %37, 1
%117 = srem i32 %116, 5
%118 = icmp eq i32 %117, 0
br i1 %118, label %119, label %123
119: ; preds = %110
%120 = tail call i32 (...) @rand()
%121 = srem i32 %120, 4
%122 = add nsw i32 %121, 1
br label %123
123: ; preds = %119, %110
%124 = phi i32 [ %122, %119 ], [ %36, %110 ]
%125 = tail call i32 @sleep(i32 100)
br label %126
126: ; preds = %123, %70
%127 = phi i32 [ %112, %123 ], [ %34, %70 ]
%128 = phi i32 [ %111, %123 ], [ %35, %70 ]
%129 = phi i32 [ %124, %123 ], [ %36, %70 ]
%130 = phi i32 [ %116, %123 ], [ %37, %70 ]
%131 = tail call i32 @system(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0))
br label %132
132: ; preds = %126, %148
%133 = phi i64 [ 0, %126 ], [ %149, %148 ]
%134 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0))
br label %135
135: ; preds = %132, %145
%136 = phi i64 [ 0, %132 ], [ %146, %145 ]
%137 = getelementptr inbounds [15 x [15 x i32]], [15 x [15 x i32]]* %1, i64 0, i64 %133, i64 %136
%138 = load i32, i32* %137
switch i32 %138, label %145 [
i32 0, label %142
i32 1, label %139
i32 10, label %140
i32 2, label %141
]
139: ; preds = %135
br label %142
140: ; preds = %135
br label %142
141: ; preds = %135
br label %142
142: ; preds = %135, %141, %140, %139
%143 = phi i32 [ 64, %139 ], [ 1, %140 ], [ 2, %141 ], [ 32, %135 ]
%144 = tail call i32 @putchar(i32 %143)
br label %145
145: ; preds = %142, %135
%146 = add nuw nsw i64 %136, 1
%147 = icmp eq i64 %146, 15
br i1 %147, label %148, label %135
148: ; preds = %145
%149 = add nuw nsw i64 %133, 1
%150 = icmp eq i64 %149, 15
br i1 %150, label %31, label %132
}