#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 /*<<< orphan*/ scanf(char *, int *);
int main() {
  int arr[100], temp = 0, i = 0, n = 0;
  scanf("%d", &n);
  for (i = 0; i < n; i++) {
    scanf("%d", &arr[i]);
  }
  for (i = 0; i < n / 2; i++) {
    temp = arr[n - i - 1];
    arr[n - i - 1] = arr[i];
    arr[i] = temp;
  }
  for (i = 0; i < n; i++) {
    printf("%d\n", arr[i]);
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1b0,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x1a4(%rbp)
movl   $0x0,-0x1a8(%rbp)
movl   $0x0,-0x1ac(%rbp)
lea    0xea9(%rip),%rdi
lea    -0x1ac(%rbp),%rsi
call   1040 <scanf@plt>
movl   $0x0,-0x1a8(%rbp)
mov    -0x1a8(%rbp),%eax
cmp    -0x1ac(%rbp),%eax
jge    11b4 <main+0x94>
movslq -0x1a8(%rbp),%rax
lea    -0x1a0(%rbp),%rsi
shl    $0x2,%rax
add    %rax,%rsi
lea    0xe65(%rip),%rdi
call   1040 <scanf@plt>
mov    -0x1a8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1a8(%rbp)
jmp    116d <main+0x4d>
movl   $0x0,-0x1a8(%rbp)
mov    -0x1a8(%rbp),%eax
mov    %eax,-0x1b0(%rbp)
mov    -0x1ac(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x1b0(%rbp),%eax
cmp    %ecx,%eax
jge    1254 <main+0x134>
mov    -0x1ac(%rbp),%eax
sub    -0x1a8(%rbp),%eax
sub    $0x1,%eax
cltq
mov    -0x1a0(%rbp,%rax,4),%eax
mov    %eax,-0x1a4(%rbp)
movslq -0x1a8(%rbp),%rax
mov    -0x1a0(%rbp,%rax,4),%ecx
mov    -0x1ac(%rbp),%eax
sub    -0x1a8(%rbp),%eax
sub    $0x1,%eax
cltq
mov    %ecx,-0x1a0(%rbp,%rax,4)
mov    -0x1a4(%rbp),%ecx
movslq -0x1a8(%rbp),%rax
mov    %ecx,-0x1a0(%rbp,%rax,4)
mov    -0x1a8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1a8(%rbp)
jmp    11be <main+0x9e>
movl   $0x0,-0x1a8(%rbp)
mov    -0x1a8(%rbp),%eax
cmp    -0x1ac(%rbp),%eax
jge    129e <main+0x17e>
movslq -0x1a8(%rbp),%rax
mov    -0x1a0(%rbp,%rax,4),%esi
lea    0xd7e(%rip),%rdi
call   1030 <printf@plt>
mov    -0x1a8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1a8(%rbp)
jmp    125e <main+0x13e>
xor    %eax,%eax
add    $0x1b0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r15
push   %r14
push   %rbx
sub    $0x1a0,%rsp
movl   $0x0,0xc(%rsp)
lea    0xec5(%rip),%rdi
lea    0xc(%rsp),%rsi
call   1040 <scanf@plt>
cmpl   $0x0,0xc(%rsp)
jle    123a <main+0x11a>
lea    0x10(%rsp),%r15
xor    %ebx,%ebx
lea    0xea2(%rip),%r14
xchg   %ax,%ax
mov    %r14,%rdi
mov    %r15,%rsi
call   1040 <scanf@plt>
add    $0x1,%rbx
movslq 0xc(%rsp),%rax
add    $0x4,%r15
cmp    %rax,%rbx
jl     1160 <main+0x40>
mov    %eax,%r9d
cmp    $0x2,%r9d
jl     1205 <main+0xe5>
mov    %r9,%r8
shr    %r8
cmp    $0x1,%r8d
jne    1196 <main+0x76>
xor    %edx,%edx
jmp    11e5 <main+0xc5>
mov    %r8d,%esi
and    $0xfffffffe,%esi
lea    -0x2(%r9),%edi
xor    %edx,%edx
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
lea    0x1(%rdi),%ebx
movslq %ebx,%rbx
mov    0x10(%rsp,%rbx,4),%ecx
mov    0x10(%rsp,%rdx,4),%eax
mov    %eax,0x10(%rsp,%rbx,4)
mov    %ecx,0x10(%rsp,%rdx,4)
movslq %edi,%rdi
mov    0x10(%rsp,%rdi,4),%eax
mov    0x14(%rsp,%rdx,4),%ecx
mov    %ecx,0x10(%rsp,%rdi,4)
mov    %eax,0x14(%rsp,%rdx,4)
add    $0x2,%rdx
add    $0xfffffffe,%edi
cmp    %rdx,%rsi
jne    11b0 <main+0x90>
test   $0x1,%r8b
je     1205 <main+0xe5>
mov    %edx,%ecx
not    %ecx
add    %r9d,%ecx
movslq %ecx,%rcx
mov    0x10(%rsp,%rcx,4),%esi
mov    0x10(%rsp,%rdx,4),%edi
mov    %edi,0x10(%rsp,%rcx,4)
mov    %esi,0x10(%rsp,%rdx,4)
test   %r9d,%r9d
jle    123a <main+0x11a>
xor    %ebx,%ebx
lea    0xdf0(%rip),%r14
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    0x10(%rsp,%rbx,4),%esi
mov    %r14,%rdi
call   1030 <printf@plt>
add    $0x1,%rbx
movslq 0xc(%rsp),%rax
cmp    %rax,%rbx
jl     1220 <main+0x100>
xor    %eax,%eax
add    $0x1a0,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [100 x i32]
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %3
store i32 0, i32* %4
store i32 0, i32* %5
%6 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %5)
store i32 0, i32* %4
br label %7
7: ; preds = %16, %0
%8 = load i32, i32* %4
%9 = load i32, i32* %5
%10 = icmp slt i32 %8, %9
br i1 %10, label %11, label %19
11: ; preds = %7
%12 = load i32, i32* %4
%13 = sext i32 %12 to i64
%14 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 %13
%15 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %14)
br label %16
16: ; preds = %11
%17 = load i32, i32* %4
%18 = add nsw i32 %17, 1
store i32 %18, i32* %4
br label %7
19: ; preds = %7
store i32 0, i32* %4
br label %20
20: ; preds = %47, %19
%21 = load i32, i32* %4
%22 = load i32, i32* %5
%23 = sdiv i32 %22, 2
%24 = icmp slt i32 %21, %23
br i1 %24, label %25, label %50
25: ; preds = %20
%26 = load i32, i32* %5
%27 = load i32, i32* %4
%28 = sub nsw i32 %26, %27
%29 = sub nsw i32 %28, 1
%30 = sext i32 %29 to i64
%31 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 %30
%32 = load i32, i32* %31
store i32 %32, i32* %3
%33 = load i32, i32* %4
%34 = sext i32 %33 to i64
%35 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 %34
%36 = load i32, i32* %35
%37 = load i32, i32* %5
%38 = load i32, i32* %4
%39 = sub nsw i32 %37, %38
%40 = sub nsw i32 %39, 1
%41 = sext i32 %40 to i64
%42 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 %41
store i32 %36, i32* %42
%43 = load i32, i32* %3
%44 = load i32, i32* %4
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 %45
store i32 %43, i32* %46
br label %47
47: ; preds = %25
%48 = load i32, i32* %4
%49 = add nsw i32 %48, 1
store i32 %49, i32* %4
br label %20
50: ; preds = %20
store i32 0, i32* %4
br label %51
51: ; preds = %61, %50
%52 = load i32, i32* %4
%53 = load i32, i32* %5
%54 = icmp slt i32 %52, %53
br i1 %54, label %55, label %64
55: ; preds = %51
%56 = load i32, i32* %4
%57 = sext i32 %56 to i64
%58 = getelementptr inbounds [100 x i32], [100 x i32]* %2, i64 0, i64 %57
%59 = load i32, i32* %58
%60 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %59)
br label %61
61: ; preds = %55
%62 = load i32, i32* %4
%63 = add nsw i32 %62, 1
store i32 %63, i32* %4
br label %51
64: ; preds = %51
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [4 x i8] c"%d\0A\00"
define i32 @main() {
%1 = alloca [100 x i32]
%2 = alloca i32
%3 = bitcast [100 x i32]* %1 to i8*
%4 = bitcast i32* %2 to i8*
store i32 0, i32* %2
%5 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
%6 = load i32, i32* %2
%7 = icmp sgt i32 %6, 0
br i1 %7, label %17, label %71
8: ; preds = %17
%9 = icmp sgt i32 %22, 1
br i1 %9, label %10, label %37
10: ; preds = %8
%11 = lshr i32 %22, 1
%12 = zext i32 %11 to i64
%13 = and i64 %12, 1
%14 = icmp eq i32 %11, 1
br i1 %14, label %25, label %15
15: ; preds = %10
%16 = and i64 %12, 2147483646
br label %39
17: ; preds = %0, %17
%18 = phi i64 [ %21, %17 ], [ 0, %0 ]
%19 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %18
%20 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %19)
%21 = add nuw nsw i64 %18, 1
%22 = load i32, i32* %2
%23 = sext i32 %22 to i64
%24 = icmp slt i64 %21, %23
br i1 %24, label %17, label %8
25: ; preds = %39, %10
%26 = phi i64 [ 0, %10 ], [ %59, %39 ]
%27 = icmp eq i64 %13, 0
br i1 %27, label %37, label %28
28: ; preds = %25
%29 = trunc i64 %26 to i32
%30 = xor i32 %29, -1
%31 = add i32 %22, %30
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %32
%34 = load i32, i32* %33
%35 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %26
%36 = load i32, i32* %35
store i32 %36, i32* %33
store i32 %34, i32* %35
br label %37
37: ; preds = %28, %25, %8
%38 = icmp sgt i32 %22, 0
br i1 %38, label %62, label %71
39: ; preds = %39, %15
%40 = phi i64 [ 0, %15 ], [ %59, %39 ]
%41 = phi i64 [ 0, %15 ], [ %60, %39 ]
%42 = trunc i64 %40 to i32
%43 = xor i32 %42, -1
%44 = add i32 %22, %43
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %45
%47 = load i32, i32* %46
%48 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %40
%49 = load i32, i32* %48
store i32 %49, i32* %46
store i32 %47, i32* %48
%50 = or i64 %40, 1
%51 = trunc i64 %50 to i32
%52 = xor i32 %51, -1
%53 = add i32 %22, %52
%54 = sext i32 %53 to i64
%55 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %54
%56 = load i32, i32* %55
%57 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %50
%58 = load i32, i32* %57
store i32 %58, i32* %55
store i32 %56, i32* %57
%59 = add nuw nsw i64 %40, 2
%60 = add i64 %41, 2
%61 = icmp eq i64 %60, %16
br i1 %61, label %25, label %39
62: ; preds = %37, %62
%63 = phi i64 [ %67, %62 ], [ 0, %37 ]
%64 = getelementptr inbounds [100 x i32], [100 x i32]* %1, i64 0, i64 %63
%65 = load i32, i32* %64
%66 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i32 %65)
%67 = add nuw nsw i64 %63, 1
%68 = load i32, i32* %2
%69 = sext i32 %68 to i64
%70 = icmp slt i64 %67, %69
br i1 %70, label %62, label %71
71: ; preds = %62, %0, %37
ret i32 0
}