#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 */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fscanf(int /*<<< orphan*/ *, char *, int *, int *, int *,
                          int *, int **);
int /*<<< orphan*/ printf(char *);
int main() {
  FILE *fp;
  int n, a, i;
  int gramma1, gramma2, gramma3, noumero;
  int theseis[a];
  fp = fopen("bus.txt", "r");
  if (fp != NULL) {
    fscanf(fp, " %c%c%c%d %d\n", &gramma1, &gramma2, &gramma3, &noumero,
           &theseis);
    fclose(fp);
  } else
    printf("To arxeio den yparxei\n");
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movl   $0x0,-0x4(%rbp)
mov    -0x18(%rbp),%eax
mov    %rsp,%rcx
mov    %rcx,-0x38(%rbp)
lea    0xf(,%rax,4),%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x48(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x40(%rbp)
lea    0xe83(%rip),%rdi
lea    0xe84(%rip),%rsi
call   1060 <fopen@plt>
mov    %rax,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
je     11d6 <main+0x96>
mov    -0x48(%rbp),%rax
mov    -0x10(%rbp),%rdi
lea    0xe63(%rip),%rsi
lea    -0x20(%rbp),%rdx
lea    -0x24(%rbp),%rcx
lea    -0x28(%rbp),%r8
lea    -0x2c(%rbp),%r9
sub    $0x10,%rsp
mov    %rax,(%rsp)
call   1050 <fscanf@plt>
add    $0x10,%rsp
mov    -0x10(%rbp),%rdi
call   1030 <fclose@plt>
jmp    11e2 <main+0xa2>
lea    0xe3b(%rip),%rdi
call   1040 <printf@plt>
mov    -0x38(%rbp),%rax
mov    %rax,%rsp
mov    -0x4(%rbp),%eax
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
sub    $0x28,%rsp
mov    %rsp,%r14
lea    0xeaf(%rip),%rdi
lea    0xeb0(%rip),%rsi
call   1060 <fopen@plt>
test   %rax,%rax
je     119b <main+0x5b>
mov    %rax,%rbx
lea    0x10(%rsp),%rax
mov    %rax,(%rsp)
lea    0xe95(%rip),%rsi
lea    0x24(%rsp),%rdx
lea    0x20(%rsp),%rcx
lea    0x1c(%rsp),%r8
lea    0x18(%rsp),%r9
mov    %rbx,%rdi
call   1050 <fscanf@plt>
mov    %rbx,%rdi
call   1040 <fclose@plt>
jmp    11a7 <main+0x67>
lea    0xe76(%rip),%rdi
call   1030 <puts@plt>
mov    %r14,%rsp
xor    %eax,%eax
add    $0x28,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [8 x i8] c"bus.txt\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [14 x i8] c" %c%c%c%d %d\0A\00"
@.str.3 = [23 x i8] c"To arxeio den yparxei\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32*
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i8*
%11 = alloca i64
store i32 0, i32* %1
%12 = load i32, i32* %4
%13 = zext i32 %12 to i64
%14 = call i8* @llvm.stacksave()
store i8* %14, i8** %10
%15 = alloca i32, i64 %13
store i64 %13, i64* %11
%16 = call i32* @fopen(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %16, i32** %2
%17 = load i32*, i32** %2
%18 = icmp ne i32* %17, null
br i1 %18, label %19, label %25
19: ; preds = %0
%20 = load i32*, i32** %2
%21 = bitcast i32* %15 to i32**
%22 = call i32 @fscanf(i32* %20, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.2, i64 0, i64 0), i32* %6, i32* %7, i32* %8, i32* %9, i32** %21)
%23 = load i32*, i32** %2
%24 = call i32 @fclose(i32* %23)
br label %27
25: ; preds = %0
%26 = call i32 @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.3, i64 0, i64 0))
br label %27
27: ; preds = %25, %19
%28 = load i8*, i8** %10
%29 = load i32, i32* %1
ret i32 %29
}

LLVM IR (-O2):
@.str = [8 x i8] c"bus.txt\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [14 x i8] c" %c%c%c%d %d\0A\00"
@str = [22 x i8] c"To arxeio den yparxei\00"
define i32 @main() {
%1 = alloca [0 x i32]
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = bitcast i32* %2 to i8*
%7 = bitcast i32* %3 to i8*
%8 = bitcast i32* %4 to i8*
%9 = bitcast i32* %5 to i8*
%10 = tail call i8* @llvm.stacksave()
%11 = tail call i32* @fopen(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%12 = icmp eq i32* %11, null
br i1 %12, label %17, label %13
13: ; preds = %0
%14 = bitcast [0 x i32]* %1 to i32**
%15 = call i32 @fscanf(i32* %11, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.2, i64 0, i64 0), i32* %2, i32* %3, i32* %4, i32* %5, i32** %14)
%16 = call i32 @fclose(i32* %11)
br label %19
17: ; preds = %0
%18 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @str, i64 0, i64 0))
br label %19
19: ; preds = %17, %13
ret i32 0
}