#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*/ run_test_case(int);
int /*<<< orphan*/ scanf(char *, int *);
int main(int argc, char const *argv[]) {
  int amount_of_properties;
  short is_first = 1;
  do {
    scanf("%d", &amount_of_properties);
    if (amount_of_properties > 0) {
      if (is_first == 1) {
        is_first = 0;
      } else {
        printf("\n");
      }
      run_test_case(amount_of_properties);
    }
  } while (amount_of_properties > 0);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movw   $0x1,-0x16(%rbp)
lea    0xead(%rip),%rdi
lea    -0x14(%rbp),%rsi
call   1050 <scanf@plt>
cmpl   $0x0,-0x14(%rbp)
jle    1192 <main+0x62>
movswl -0x16(%rbp),%eax
cmp    $0x1,%eax
jne    117e <main+0x4e>
movw   $0x0,-0x16(%rbp)
jmp    118a <main+0x5a>
lea    0xe7e(%rip),%rdi
call   1030 <printf@plt>
mov    -0x14(%rbp),%edi
call   1040 <run_test_case@plt>
jmp    1197 <main+0x67>
cmpl   $0x0,-0x14(%rbp)
jg     114c <main+0x1c>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
sub    $0x10,%rsp
mov    $0x1,%bp
lea    0xebd(%rip),%r14
lea    0xc(%rsp),%rbx
jmp    116a <main+0x3a>
nopw   0x0(%rax,%rax,1)
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    0xc(%rsp),%edi
call   1040 <run_test_case@plt>
cmpl   $0x0,0xc(%rsp)
jle    1187 <main+0x57>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1050 <scanf@plt>
mov    0xc(%rsp),%edi
test   %edi,%edi
jle    1187 <main+0x57>
cmp    $0x1,%bp
jne    1150 <main+0x20>
xor    %ebp,%ebp
jmp    115e <main+0x2e>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
pop    %r14
pop    %rbp
ret

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

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