#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 /*<<< orphan*/ scanf(char *, char *);
int main() {
  int index = 0;
  int counter = 0;
  char help;
  char card[13];
  scanf("%s[^ \n]", card);
  for (index = 0; index < 13; index++) {
    for (counter = 0; counter < 13; counter++) {
      if (card[counter] == '2') {
        help = card[0];
        card[0] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == '3') {
        help = card[1];
        card[1] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == '4') {
        help = card[2];
        card[2] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == '5') {
        help = card[3];
        card[3] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == '6') {
        help = card[4];
        card[4] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == '7') {
        help = card[5];
        card[5] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == '8') {
        help = card[6];
        card[6] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == '9') {
        help = card[7];
        card[7] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == 'T') {
        help = card[8];
        card[8] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == 'J') {
        help = card[9];
        card[9] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == 'Q') {
        help = card[10];
        card[10] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == 'K') {
        help = card[11];
        card[11] = card[counter];
        card[counter] = help;
      }
      if (card[counter] == 'A') {
        help = card[12];
        card[12] = card[counter];
        card[counter] = help;
      }
    }
  }
  for (counter = 0; counter < 13; counter++)
    printf("%c", card[counter]);
  printf("\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
movl   $0x0,-0xc(%rbp)
lea    -0x1a(%rbp),%rsi
lea    0xeb8(%rip),%rdi
call   1040 <scanf@plt>
movl   $0x0,-0x8(%rbp)
cmpl   $0xd,-0x8(%rbp)
jge    13eb <main+0x2cb>
movl   $0x0,-0xc(%rbp)
cmpl   $0xd,-0xc(%rbp)
jge    13d8 <main+0x2b8>
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x32,%eax
jne    119d <main+0x7d>
mov    -0x1a(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x1a(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x33,%eax
jne    11cb <main+0xab>
mov    -0x19(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x19(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x34,%eax
jne    11f9 <main+0xd9>
mov    -0x18(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x18(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x35,%eax
jne    1227 <main+0x107>
mov    -0x17(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x17(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x36,%eax
jne    1255 <main+0x135>
mov    -0x16(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x16(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x37,%eax
jne    1283 <main+0x163>
mov    -0x15(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x15(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x38,%eax
jne    12b1 <main+0x191>
mov    -0x14(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x14(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x39,%eax
jne    12df <main+0x1bf>
mov    -0x13(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x13(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x54,%eax
jne    130d <main+0x1ed>
mov    -0x12(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x12(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x4a,%eax
jne    133b <main+0x21b>
mov    -0x11(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x11(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x51,%eax
jne    1369 <main+0x249>
mov    -0x10(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0x10(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x4b,%eax
jne    1397 <main+0x277>
mov    -0xf(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0xf(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%eax
cmp    $0x41,%eax
jne    13c5 <main+0x2a5>
mov    -0xe(%rbp),%al
mov    %al,-0xd(%rbp)
movslq -0xc(%rbp),%rax
mov    -0x1a(%rbp,%rax,1),%al
mov    %al,-0xe(%rbp)
mov    -0xd(%rbp),%cl
movslq -0xc(%rbp),%rax
mov    %cl,-0x1a(%rbp,%rax,1)
jmp    13ca <main+0x2aa>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1165 <main+0x45>
jmp    13dd <main+0x2bd>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1154 <main+0x34>
movl   $0x0,-0xc(%rbp)
cmpl   $0xd,-0xc(%rbp)
jge    1421 <main+0x301>
movslq -0xc(%rbp),%rax
movsbl -0x1a(%rbp,%rax,1),%esi
lea    0xbfc(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    13f2 <main+0x2d2>
lea    0xbe3(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x18,%rsp
lea    0xed5(%rip),%rdi
lea    0xb(%rsp),%rsi
call   1040 <scanf@plt>
xor    %eax,%eax
jmp    114c <main+0x2c>
nopl   0x0(%rax)
add    $0x1,%eax
cmp    $0xd,%eax
je     12f3 <main+0x1d3>
xor    %ecx,%ecx
jmp    115a <main+0x3a>
add    $0x1,%rcx
cmp    $0xd,%rcx
je     1140 <main+0x20>
movzbl 0xb(%rsp,%rcx,1),%edx
cmp    $0x32,%dl
je     11d0 <main+0xb0>
cmp    $0x33,%dl
je     11e3 <main+0xc3>
cmp    $0x34,%dl
je     11fa <main+0xda>
cmp    $0x35,%dl
je     1211 <main+0xf1>
cmp    $0x36,%dl
je     1228 <main+0x108>
cmp    $0x37,%dl
je     123f <main+0x11f>
cmp    $0x38,%dl
je     1256 <main+0x136>
cmp    $0x39,%dl
je     126d <main+0x14d>
cmp    $0x54,%dl
je     1284 <main+0x164>
cmp    $0x4a,%dl
je     129b <main+0x17b>
cmp    $0x51,%dl
je     12b2 <main+0x192>
cmp    $0x4b,%dl
je     12c9 <main+0x1a9>
cmp    $0x41,%dl
jne    1150 <main+0x30>
jmp    12e0 <main+0x1c0>
nopl   (%rax)
movzbl 0xb(%rsp),%edx
movb   $0x32,0xb(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x33,%dl
jne    1169 <main+0x49>
movzbl 0xc(%rsp),%edx
movb   $0x33,0xc(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x34,%dl
jne    1172 <main+0x52>
movzbl 0xd(%rsp),%edx
movb   $0x34,0xd(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x35,%dl
jne    117b <main+0x5b>
movzbl 0xe(%rsp),%edx
movb   $0x35,0xe(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x36,%dl
jne    1184 <main+0x64>
movzbl 0xf(%rsp),%edx
movb   $0x36,0xf(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x37,%dl
jne    118d <main+0x6d>
movzbl 0x10(%rsp),%edx
movb   $0x37,0x10(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x38,%dl
jne    1196 <main+0x76>
movzbl 0x11(%rsp),%edx
movb   $0x38,0x11(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x39,%dl
jne    119f <main+0x7f>
movzbl 0x12(%rsp),%edx
movb   $0x39,0x12(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x54,%dl
jne    11a8 <main+0x88>
movzbl 0x13(%rsp),%edx
movb   $0x54,0x13(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x4a,%dl
jne    11b1 <main+0x91>
movzbl 0x14(%rsp),%edx
movb   $0x4a,0x14(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x51,%dl
jne    11ba <main+0x9a>
movzbl 0x15(%rsp),%edx
movb   $0x51,0x15(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x4b,%dl
jne    11c3 <main+0xa3>
movzbl 0x16(%rsp),%edx
movb   $0x4b,0x16(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
cmp    $0x41,%dl
jne    1150 <main+0x30>
movzbl 0x17(%rsp),%edx
movb   $0x41,0x17(%rsp)
mov    %dl,0xb(%rsp,%rcx,1)
jmp    1150 <main+0x30>
movsbl 0xb(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0xc(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0xd(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0xe(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0xf(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x10(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x11(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x12(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x13(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x14(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x15(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x16(%rsp),%edi
call   1030 <putchar@plt>
movsbl 0x17(%rsp),%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
xor    %eax,%eax
add    $0x18,%rsp
ret

LLVM IR (-O0):
@.str = [8 x i8] c"%s[^ \0A]\00"
@.str.1 = [3 x i8] c"%c\00"
@.str.2 = [2 x i8] c"\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i8
%5 = alloca [13 x i8]
store i32 0, i32* %1
store i32 0, i32* %2
store i32 0, i32* %3
%6 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 0
%7 = call i32 @scanf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8* %6)
store i32 0, i32* %2
br label %8
8: ; preds = %267, %0
%9 = load i32, i32* %2
%10 = icmp slt i32 %9, 13
br i1 %10, label %11, label %270
11: ; preds = %8
store i32 0, i32* %3
br label %12
12: ; preds = %263, %11
%13 = load i32, i32* %3
%14 = icmp slt i32 %13, 13
br i1 %14, label %15, label %266
15: ; preds = %12
%16 = load i32, i32* %3
%17 = sext i32 %16 to i64
%18 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %17
%19 = load i8, i8* %18
%20 = sext i8 %19 to i32
%21 = icmp eq i32 %20, 50
br i1 %21, label %22, label %34
22: ; preds = %15
%23 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 0
%24 = load i8, i8* %23
store i8 %24, i8* %4
%25 = load i32, i32* %3
%26 = sext i32 %25 to i64
%27 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %26
%28 = load i8, i8* %27
%29 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 0
store i8 %28, i8* %29
%30 = load i8, i8* %4
%31 = load i32, i32* %3
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %32
store i8 %30, i8* %33
br label %34
34: ; preds = %22, %15
%35 = load i32, i32* %3
%36 = sext i32 %35 to i64
%37 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %36
%38 = load i8, i8* %37
%39 = sext i8 %38 to i32
%40 = icmp eq i32 %39, 51
br i1 %40, label %41, label %53
41: ; preds = %34
%42 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 1
%43 = load i8, i8* %42
store i8 %43, i8* %4
%44 = load i32, i32* %3
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %45
%47 = load i8, i8* %46
%48 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 1
store i8 %47, i8* %48
%49 = load i8, i8* %4
%50 = load i32, i32* %3
%51 = sext i32 %50 to i64
%52 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %51
store i8 %49, i8* %52
br label %53
53: ; preds = %41, %34
%54 = load i32, i32* %3
%55 = sext i32 %54 to i64
%56 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %55
%57 = load i8, i8* %56
%58 = sext i8 %57 to i32
%59 = icmp eq i32 %58, 52
br i1 %59, label %60, label %72
60: ; preds = %53
%61 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 2
%62 = load i8, i8* %61
store i8 %62, i8* %4
%63 = load i32, i32* %3
%64 = sext i32 %63 to i64
%65 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %64
%66 = load i8, i8* %65
%67 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 2
store i8 %66, i8* %67
%68 = load i8, i8* %4
%69 = load i32, i32* %3
%70 = sext i32 %69 to i64
%71 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %70
store i8 %68, i8* %71
br label %72
72: ; preds = %60, %53
%73 = load i32, i32* %3
%74 = sext i32 %73 to i64
%75 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %74
%76 = load i8, i8* %75
%77 = sext i8 %76 to i32
%78 = icmp eq i32 %77, 53
br i1 %78, label %79, label %91
79: ; preds = %72
%80 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 3
%81 = load i8, i8* %80
store i8 %81, i8* %4
%82 = load i32, i32* %3
%83 = sext i32 %82 to i64
%84 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %83
%85 = load i8, i8* %84
%86 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 3
store i8 %85, i8* %86
%87 = load i8, i8* %4
%88 = load i32, i32* %3
%89 = sext i32 %88 to i64
%90 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %89
store i8 %87, i8* %90
br label %91
91: ; preds = %79, %72
%92 = load i32, i32* %3
%93 = sext i32 %92 to i64
%94 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %93
%95 = load i8, i8* %94
%96 = sext i8 %95 to i32
%97 = icmp eq i32 %96, 54
br i1 %97, label %98, label %110
98: ; preds = %91
%99 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 4
%100 = load i8, i8* %99
store i8 %100, i8* %4
%101 = load i32, i32* %3
%102 = sext i32 %101 to i64
%103 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %102
%104 = load i8, i8* %103
%105 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 4
store i8 %104, i8* %105
%106 = load i8, i8* %4
%107 = load i32, i32* %3
%108 = sext i32 %107 to i64
%109 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %108
store i8 %106, i8* %109
br label %110
110: ; preds = %98, %91
%111 = load i32, i32* %3
%112 = sext i32 %111 to i64
%113 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %112
%114 = load i8, i8* %113
%115 = sext i8 %114 to i32
%116 = icmp eq i32 %115, 55
br i1 %116, label %117, label %129
117: ; preds = %110
%118 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 5
%119 = load i8, i8* %118
store i8 %119, i8* %4
%120 = load i32, i32* %3
%121 = sext i32 %120 to i64
%122 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %121
%123 = load i8, i8* %122
%124 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 5
store i8 %123, i8* %124
%125 = load i8, i8* %4
%126 = load i32, i32* %3
%127 = sext i32 %126 to i64
%128 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %127
store i8 %125, i8* %128
br label %129
129: ; preds = %117, %110
%130 = load i32, i32* %3
%131 = sext i32 %130 to i64
%132 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %131
%133 = load i8, i8* %132
%134 = sext i8 %133 to i32
%135 = icmp eq i32 %134, 56
br i1 %135, label %136, label %148
136: ; preds = %129
%137 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 6
%138 = load i8, i8* %137
store i8 %138, i8* %4
%139 = load i32, i32* %3
%140 = sext i32 %139 to i64
%141 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %140
%142 = load i8, i8* %141
%143 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 6
store i8 %142, i8* %143
%144 = load i8, i8* %4
%145 = load i32, i32* %3
%146 = sext i32 %145 to i64
%147 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %146
store i8 %144, i8* %147
br label %148
148: ; preds = %136, %129
%149 = load i32, i32* %3
%150 = sext i32 %149 to i64
%151 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %150
%152 = load i8, i8* %151
%153 = sext i8 %152 to i32
%154 = icmp eq i32 %153, 57
br i1 %154, label %155, label %167
155: ; preds = %148
%156 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 7
%157 = load i8, i8* %156
store i8 %157, i8* %4
%158 = load i32, i32* %3
%159 = sext i32 %158 to i64
%160 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %159
%161 = load i8, i8* %160
%162 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 7
store i8 %161, i8* %162
%163 = load i8, i8* %4
%164 = load i32, i32* %3
%165 = sext i32 %164 to i64
%166 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %165
store i8 %163, i8* %166
br label %167
167: ; preds = %155, %148
%168 = load i32, i32* %3
%169 = sext i32 %168 to i64
%170 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %169
%171 = load i8, i8* %170
%172 = sext i8 %171 to i32
%173 = icmp eq i32 %172, 84
br i1 %173, label %174, label %186
174: ; preds = %167
%175 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 8
%176 = load i8, i8* %175
store i8 %176, i8* %4
%177 = load i32, i32* %3
%178 = sext i32 %177 to i64
%179 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %178
%180 = load i8, i8* %179
%181 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 8
store i8 %180, i8* %181
%182 = load i8, i8* %4
%183 = load i32, i32* %3
%184 = sext i32 %183 to i64
%185 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %184
store i8 %182, i8* %185
br label %186
186: ; preds = %174, %167
%187 = load i32, i32* %3
%188 = sext i32 %187 to i64
%189 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %188
%190 = load i8, i8* %189
%191 = sext i8 %190 to i32
%192 = icmp eq i32 %191, 74
br i1 %192, label %193, label %205
193: ; preds = %186
%194 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 9
%195 = load i8, i8* %194
store i8 %195, i8* %4
%196 = load i32, i32* %3
%197 = sext i32 %196 to i64
%198 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %197
%199 = load i8, i8* %198
%200 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 9
store i8 %199, i8* %200
%201 = load i8, i8* %4
%202 = load i32, i32* %3
%203 = sext i32 %202 to i64
%204 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %203
store i8 %201, i8* %204
br label %205
205: ; preds = %193, %186
%206 = load i32, i32* %3
%207 = sext i32 %206 to i64
%208 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %207
%209 = load i8, i8* %208
%210 = sext i8 %209 to i32
%211 = icmp eq i32 %210, 81
br i1 %211, label %212, label %224
212: ; preds = %205
%213 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 10
%214 = load i8, i8* %213
store i8 %214, i8* %4
%215 = load i32, i32* %3
%216 = sext i32 %215 to i64
%217 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %216
%218 = load i8, i8* %217
%219 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 10
store i8 %218, i8* %219
%220 = load i8, i8* %4
%221 = load i32, i32* %3
%222 = sext i32 %221 to i64
%223 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %222
store i8 %220, i8* %223
br label %224
224: ; preds = %212, %205
%225 = load i32, i32* %3
%226 = sext i32 %225 to i64
%227 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %226
%228 = load i8, i8* %227
%229 = sext i8 %228 to i32
%230 = icmp eq i32 %229, 75
br i1 %230, label %231, label %243
231: ; preds = %224
%232 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 11
%233 = load i8, i8* %232
store i8 %233, i8* %4
%234 = load i32, i32* %3
%235 = sext i32 %234 to i64
%236 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %235
%237 = load i8, i8* %236
%238 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 11
store i8 %237, i8* %238
%239 = load i8, i8* %4
%240 = load i32, i32* %3
%241 = sext i32 %240 to i64
%242 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %241
store i8 %239, i8* %242
br label %243
243: ; preds = %231, %224
%244 = load i32, i32* %3
%245 = sext i32 %244 to i64
%246 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %245
%247 = load i8, i8* %246
%248 = sext i8 %247 to i32
%249 = icmp eq i32 %248, 65
br i1 %249, label %250, label %262
250: ; preds = %243
%251 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 12
%252 = load i8, i8* %251
store i8 %252, i8* %4
%253 = load i32, i32* %3
%254 = sext i32 %253 to i64
%255 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %254
%256 = load i8, i8* %255
%257 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 12
store i8 %256, i8* %257
%258 = load i8, i8* %4
%259 = load i32, i32* %3
%260 = sext i32 %259 to i64
%261 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %260
store i8 %258, i8* %261
br label %262
262: ; preds = %250, %243
br label %263
263: ; preds = %262
%264 = load i32, i32* %3
%265 = add nsw i32 %264, 1
store i32 %265, i32* %3
br label %12
266: ; preds = %12
br label %267
267: ; preds = %266
%268 = load i32, i32* %2
%269 = add nsw i32 %268, 1
store i32 %269, i32* %2
br label %8
270: ; preds = %8
store i32 0, i32* %3
br label %271
271: ; preds = %281, %270
%272 = load i32, i32* %3
%273 = icmp slt i32 %272, 13
br i1 %273, label %274, label %284
274: ; preds = %271
%275 = load i32, i32* %3
%276 = sext i32 %275 to i64
%277 = getelementptr inbounds [13 x i8], [13 x i8]* %5, i64 0, i64 %276
%278 = load i8, i8* %277
%279 = sext i8 %278 to i32
%280 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32 %279)
br label %281
281: ; preds = %274
%282 = load i32, i32* %3
%283 = add nsw i32 %282, 1
store i32 %283, i32* %3
br label %271
284: ; preds = %271
%285 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
ret i32 0
}

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