#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 /*<<< orphan*/ scanf(char *, int *, ...);
int main() {
  int surfaceN;
  scanf("%d", &surfaceN);
  for (int i = 0; i < surfaceN; i++) {
    int landX;
    int landY;
    scanf("%d%d", &landX, &landY);
  }
  while (42) {
    int X;
    int Y;
    int hSpeed;
    int vSpeed;
    int fuel;
    int rotate;
    int power;
    scanf("%d%d%d%d%d%d%d", &X, &Y, &hSpeed, &vSpeed, &fuel, &rotate, &power);
    if (vSpeed > -40)
      printf("0 0\n");
    else
      printf("0 4\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xed6(%rip),%rdi
lea    -0x8(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x0,-0xc(%rbp)
mov    -0xc(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1178 <main+0x58>
lea    0xeaf(%rip),%rdi
lea    -0x10(%rbp),%rsi
lea    -0x14(%rbp),%rdx
mov    $0x0,%al
call   1040 <scanf@plt>
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1148 <main+0x28>
jmp    117d <main+0x5d>
lea    0xe7c(%rip),%rdi
lea    -0x18(%rbp),%rsi
lea    -0x1c(%rbp),%rdx
lea    -0x20(%rbp),%rcx
lea    -0x24(%rbp),%r8
lea    -0x28(%rbp),%r9
lea    -0x2c(%rbp),%r10
lea    -0x30(%rbp),%rax
mov    %r10,(%rsp)
mov    %rax,0x8(%rsp)
mov    $0x0,%al
call   1040 <scanf@plt>
cmpl   $0xffffffd8,-0x24(%rbp)
jle    11cb <main+0xab>
lea    0xe4e(%rip),%rdi
call   1030 <printf@plt>
jmp    11d7 <main+0xb7>
lea    0xe42(%rip),%rdi
call   1030 <printf@plt>
jmp    117d <main+0x5d>

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %rbx
sub    $0x28,%rsp
lea    0xedb(%rip),%rdi
lea    0x8(%rsp),%rsi
xor    %eax,%eax
call   1040 <scanf@plt>
cmpl   $0x0,0x8(%rsp)
jle    1180 <main+0x60>
lea    0xebf(%rip),%r14
lea    0x14(%rsp),%r15
lea    0x10(%rsp),%rbx
xor    %ebp,%ebp
nopw   0x0(%rax,%rax,1)
mov    %r14,%rdi
mov    %r15,%rsi
mov    %rbx,%rdx
xor    %eax,%eax
call   1040 <scanf@plt>
add    $0x1,%ebp
cmp    0x8(%rsp),%ebp
jl     1160 <main+0x40>
nopl   0x0(%rax)
lea    0x18(%rsp),%rbp
lea    0x1c(%rsp),%rbx
lea    0xe6f(%rip),%rdi
lea    0x14(%rsp),%rsi
lea    0x10(%rsp),%rdx
lea    0x24(%rsp),%rcx
lea    0xc(%rsp),%r8
lea    0x20(%rsp),%r9
xor    %eax,%eax
push   %rbp
push   %rbx
call   1040 <scanf@plt>
add    $0x10,%rsp
cmpl   $0xffffffd9,0xc(%rsp)
lea    0xe50(%rip),%rax
lea    0xe45(%rip),%rdi
cmovge %rax,%rdi
call   1030 <puts@plt>
jmp    1180 <main+0x60>

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [5 x i8] c"%d%d\00"
@.str.2 = [15 x i8] c"%d%d%d%d%d%d%d\00"
@.str.3 = [5 x i8] c"0 0\0A\00"
@.str.4 = [5 x i8] c"0 4\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 i32
%11 = alloca i32
%12 = alloca i32
store i32 0, i32* %1
%13 = call i32 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %2)
store i32 0, i32* %3
br label %14
14: ; preds = %20, %0
%15 = load i32, i32* %3
%16 = load i32, i32* %2
%17 = icmp slt i32 %15, %16
br i1 %17, label %18, label %23
18: ; preds = %14
%19 = call i32 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32* %4, i32* %5)
br label %20
20: ; preds = %18
%21 = load i32, i32* %3
%22 = add nsw i32 %21, 1
store i32 %22, i32* %3
br label %14
23: ; preds = %14
br label %24
24: ; preds = %23, %32
%25 = call i32 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), i32* %6, i32* %7, i32* %8, i32* %9, i32* %10, i32* %11, i32* %12)
%26 = load i32, i32* %9
%27 = icmp sgt i32 %26, -40
br i1 %27, label %28, label %30
28: ; preds = %24
%29 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.3, i64 0, i64 0))
br label %32
30: ; preds = %24
%31 = call i32 @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.4, i64 0, i64 0))
br label %32
32: ; preds = %30, %28
br label %24
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@.str.1 = [5 x i8] c"%d%d\00"
@.str.2 = [15 x i8] c"%d%d%d%d%d%d%d\00"
@str = [4 x i8] c"0 4\00"
@str.5 = [4 x i8] c"0 0\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 i32
%11 = bitcast i32* %1 to i8*
%12 = call i32 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32* %1)
%13 = load i32, i32* %1
%14 = icmp sgt i32 %13, 0
br i1 %14, label %15, label %18
15: ; preds = %0
%16 = bitcast i32* %2 to i8*
%17 = bitcast i32* %3 to i8*
br label %26
18: ; preds = %26, %0
%19 = bitcast i32* %4 to i8*
%20 = bitcast i32* %5 to i8*
%21 = bitcast i32* %6 to i8*
%22 = bitcast i32* %7 to i8*
%23 = bitcast i32* %8 to i8*
%24 = bitcast i32* %9 to i8*
%25 = bitcast i32* %10 to i8*
br label %32
26: ; preds = %15, %26
%27 = phi i32 [ 0, %15 ], [ %29, %26 ]
%28 = call i32 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32* %2, i32* %3)
%29 = add nuw nsw i32 %27, 1
%30 = load i32, i32* %1
%31 = icmp slt i32 %29, %30
br i1 %31, label %26, label %18
32: ; preds = %18, %32
%33 = call i32 (i8*, i32*, ...) @scanf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), i32* %4, i32* %5, i32* %6, i32* %7, i32* %8, i32* %9, i32* %10)
%34 = load i32, i32* %7
%35 = icmp sgt i32 %34, -40
%36 = select i1 %35, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @str.5, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @str, i64 0, i64 0)
%37 = call i32 @puts(i8* dereferenceable(1) %36)
br label %32
}