#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, int);
int /*<<< orphan*/ scanf(char *, int *, int *);
int main() {
  int a, b;
  scanf("%d%d", &a, &b);
  if (a > b) {
    printf("%d %d\n", b, a);
  } else if (a < b) {
    printf("%d %d\n", a, b);
  } else {
    printf("%d %d\n", a, a);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
call   1040 <scanf@plt>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jle    1166 <main+0x46>
mov    -0xc(%rbp),%esi
mov    -0x8(%rbp),%edx
lea    0xea9(%rip),%rdi
call   1030 <printf@plt>
jmp    11a0 <main+0x80>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1189 <main+0x69>
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
lea    0xe86(%rip),%rdi
call   1030 <printf@plt>
jmp    119b <main+0x7b>
mov    -0x8(%rbp),%esi
mov    -0x8(%rbp),%edx
lea    0xe6f(%rip),%rdi
call   1030 <printf@plt>
jmp    11a0 <main+0x80>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rdi
lea    0x4(%rsp),%rsi
mov    %rsp,%rdx
call   1040 <scanf@plt>
mov    0x4(%rsp),%edx
mov    (%rsp),%eax
lea    0xec2(%rip),%rdi
cmp    %eax,%edx
jle    114b <main+0x2b>
mov    %eax,%esi
jmp    1155 <main+0x35>
jge    1153 <main+0x33>
mov    %edx,%esi
mov    %eax,%edx
jmp    1155 <main+0x35>
mov    %edx,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [5 x i8] c"%d%d\00"
@.str.1 = [7 x i8] c"%d %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
%4 = call i32 @scanf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32* %2, i32* %3)
%5 = load i32, i32* %2
%6 = load i32, i32* %3
%7 = icmp sgt i32 %5, %6
br i1 %7, label %8, label %12
8: ; preds = %0
%9 = load i32, i32* %3
%10 = load i32, i32* %2
%11 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %9, i32 %10)
br label %25
12: ; preds = %0
%13 = load i32, i32* %2
%14 = load i32, i32* %3
%15 = icmp slt i32 %13, %14
br i1 %15, label %16, label %20
16: ; preds = %12
%17 = load i32, i32* %2
%18 = load i32, i32* %3
%19 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %17, i32 %18)
br label %24
20: ; preds = %12
%21 = load i32, i32* %2
%22 = load i32, i32* %2
%23 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %21, i32 %22)
br label %24
24: ; preds = %20, %16
br label %25
25: ; preds = %24, %8
ret i32 0
}

LLVM IR (-O2):
@.str = [5 x i8] c"%d%d\00"
@.str.1 = [7 x i8] c"%d %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = bitcast i32* %1 to i8*
%4 = bitcast i32* %2 to i8*
%5 = call i32 @scanf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32* %1, i32* %2)
%6 = load i32, i32* %1
%7 = load i32, i32* %2
%8 = icmp sgt i32 %6, %7
br i1 %8, label %9, label %11
9: ; preds = %0
%10 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %7, i32 %6)
br label %17
11: ; preds = %0
%12 = icmp slt i32 %6, %7
br i1 %12, label %13, label %15
13: ; preds = %11
%14 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %6, i32 %7)
br label %17
15: ; preds = %11
%16 = call i32 @printf(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %6, i32 %6)
br label %17
17: ; preds = %13, %15, %9
ret i32 0
}