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


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x14(%rbp)
lea    0xec3(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
lea    -0x10(%rbp),%rcx
call   1040 <scanf@plt>
mov    -0x8(%rbp),%eax
cmp    -0xc(%rbp),%eax
jl     116c <main+0x4c>
mov    -0xc(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0x10(%rbp),%eax
jl     118a <main+0x6a>
mov    -0x10(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x8(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x10(%rbp),%eax
jl     11a8 <main+0x88>
mov    -0x10(%rbp),%eax
mov    %eax,-0x14(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x10(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
mov    -0x10(%rbp),%ecx
lea    0xe4f(%rip),%rdi
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    0x14(%rsp),%rsi
lea    0x10(%rsp),%rdx
lea    0xc(%rsp),%rcx
call   1040 <scanf@plt>
mov    0x14(%rsp),%ecx
mov    0x10(%rsp),%edx
cmp    %edx,%ecx
jge    1151 <main+0x31>
mov    %edx,%eax
mov    %ecx,%edx
jmp    115b <main+0x3b>
mov    %ecx,0x10(%rsp)
mov    %edx,0x14(%rsp)
mov    %ecx,%eax
mov    0xc(%rsp),%ecx
cmp    %ecx,%edx
jge    1177 <main+0x57>
mov    %edx,%esi
mov    %ecx,%edx
cmp    %edx,%eax
jl     1185 <main+0x65>
mov    %eax,0xc(%rsp)
mov    %edx,0x10(%rsp)
mov    %eax,%ecx
jmp    1189 <main+0x69>
mov    %edx,0xc(%rsp)
mov    %ecx,0x14(%rsp)
mov    %ecx,%esi
cmp    %edx,%eax
jge    116b <main+0x4b>
mov    %edx,%ecx
mov    %eax,%edx
lea    0xe77(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x18,%rsp
ret

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

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