#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*/ gets(char *);
int /*<<< orphan*/ puts(char *);
scalar_t__ strlen(char *);
int main() {
  char x[28], y[28];
  gets(x);
  gets(y);
  if (strlen(x) >= strlen(y)) {
    puts(x);
    puts(y);
  } else {
    puts(y);
    puts(x);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x20(%rbp),%rdi
call   1050 <gets@plt>
lea    -0x40(%rbp),%rdi
call   1050 <gets@plt>
lea    -0x20(%rbp),%rdi
call   1040 <strlen@plt>
mov    %rax,-0x48(%rbp)
lea    -0x40(%rbp),%rdi
call   1040 <strlen@plt>
mov    %rax,%rcx
mov    -0x48(%rbp),%rax
cmp    %rcx,%rax
jl     118e <main+0x5e>
lea    -0x20(%rbp),%rdi
call   1030 <puts@plt>
lea    -0x40(%rbp),%rdi
call   1030 <puts@plt>
jmp    11a0 <main+0x70>
lea    -0x40(%rbp),%rdi
call   1030 <puts@plt>
lea    -0x20(%rbp),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %rbx
sub    $0x40,%rsp
lea    0x20(%rsp),%r14
mov    %r14,%rdi
call   1050 <gets@plt>
mov    %rsp,%rbx
mov    %rbx,%rdi
call   1050 <gets@plt>
mov    %r14,%rdi
call   1040 <strlen@plt>
mov    %rax,%r15
mov    %rbx,%rdi
call   1040 <strlen@plt>
cmp    %rax,%r15
mov    %r14,%rdi
cmovl  %rbx,%rdi
cmovl  %r14,%rbx
call   1030 <puts@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca [28 x i8]
%3 = alloca [28 x i8]
store i32 0, i32* %1
%4 = getelementptr inbounds [28 x i8], [28 x i8]* %2, i64 0, i64 0
%5 = call i32 @gets(i8* %4)
%6 = getelementptr inbounds [28 x i8], [28 x i8]* %3, i64 0, i64 0
%7 = call i32 @gets(i8* %6)
%8 = getelementptr inbounds [28 x i8], [28 x i8]* %2, i64 0, i64 0
%9 = call i64 @strlen(i8* %8)
%10 = getelementptr inbounds [28 x i8], [28 x i8]* %3, i64 0, i64 0
%11 = call i64 @strlen(i8* %10)
%12 = icmp sge i64 %9, %11
br i1 %12, label %13, label %18
13: ; preds = %0
%14 = getelementptr inbounds [28 x i8], [28 x i8]* %2, i64 0, i64 0
%15 = call i32 @puts(i8* %14)
%16 = getelementptr inbounds [28 x i8], [28 x i8]* %3, i64 0, i64 0
%17 = call i32 @puts(i8* %16)
br label %23
18: ; preds = %0
%19 = getelementptr inbounds [28 x i8], [28 x i8]* %3, i64 0, i64 0
%20 = call i32 @puts(i8* %19)
%21 = getelementptr inbounds [28 x i8], [28 x i8]* %2, i64 0, i64 0
%22 = call i32 @puts(i8* %21)
br label %23
23: ; preds = %18, %13
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = alloca [28 x i8]
%2 = alloca [28 x i8]
%3 = getelementptr inbounds [28 x i8], [28 x i8]* %1, i64 0, i64 0
%4 = getelementptr inbounds [28 x i8], [28 x i8]* %2, i64 0, i64 0
%5 = call i32 @gets(i8* %3)
%6 = call i32 @gets(i8* %4)
%7 = call i64 @strlen(i8* %3)
%8 = call i64 @strlen(i8* %4)
%9 = icmp slt i64 %7, %8
%10 = select i1 %9, i8* %4, i8* %3
%11 = select i1 %9, i8* %3, i8* %4
%12 = call i32 @puts(i8* %10)
%13 = call i32 @puts(i8* %11)
ret i32 0
}