#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 */
scalar_t__ EOF;
int /*<<< orphan*/ printf(char *, int, int);
scalar_t__ scanf(char *, int *);
int main() {
  int n;
  while (scanf("%d\n", &n) != EOF && n != 0) {
    if (n > 100) {
      printf("f91(%d) = %d\n", n, n - 10);
    } else {
      printf("f91(%d) = %d\n", n, 91);
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xed4(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
mov    %rax,%rcx
xor    %eax,%eax
mov    0x2e9d(%rip),%rdx
cmp    (%rdx),%rcx
mov    %al,-0x9(%rbp)
je     1161 <main+0x41>
cmpl   $0x0,-0x8(%rbp)
setne  %al
mov    %al,-0x9(%rbp)
mov    -0x9(%rbp),%al
test   $0x1,%al
jne    1171 <main+0x51>
jmp    11ae <main+0x8e>
cmpl   $0x64,-0x8(%rbp)
jle    1195 <main+0x75>
mov    -0x8(%rbp),%esi
mov    -0x8(%rbp),%edx
sub    $0xa,%edx
lea    0xe75(%rip),%rdi
call   1030 <printf@plt>
jmp    11a9 <main+0x89>
mov    -0x8(%rbp),%esi
lea    0xe61(%rip),%rdi
mov    $0x5b,%edx
call   1030 <printf@plt>
jmp    112f <main+0xf>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x10,%rsp
lea    0xed7(%rip),%rdi
lea    0xc(%rsp),%rsi
call   1040 <scanf@plt>
mov    0x2ea4(%rip),%r12
cmp    (%r12),%rax
je     119a <main+0x7a>
mov    0xc(%rsp),%esi
test   %esi,%esi
je     119a <main+0x7a>
mov    $0x5b,%ebp
lea    0xea2(%rip),%r14
lea    0xea5(%rip),%r15
lea    0xc(%rsp),%rbx
nopw   0x0(%rax,%rax,1)
lea    -0xa(%rsi),%edx
cmp    $0x65,%esi
cmovl  %ebp,%edx
mov    %r14,%rdi
call   1030 <printf@plt>
mov    %r15,%rdi
mov    %rbx,%rsi
call   1040 <scanf@plt>
cmp    (%r12),%rax
je     119a <main+0x7a>
mov    0xc(%rsp),%esi
test   %esi,%esi
jne    1170 <main+0x50>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

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

LLVM IR (-O2):
@.str = [4 x i8] c"%d\0A\00"
@EOF = global i64 0
@.str.1 = [14 x i8] c"f91(%d) = %d\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = bitcast i32* %1 to i8*
%3 = call i64 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32* %1)
%4 = load i64, i64* @EOF
%5 = icmp ne i64 %3, %4
%6 = load i32, i32* %1
%7 = icmp ne i32 %6, 0
%8 = select i1 %5, i1 %7, i1 false
br i1 %8, label %9, label %21
9: ; preds = %0, %9
%10 = phi i32 [ %18, %9 ], [ %6, %0 ]
%11 = icmp sgt i32 %10, 100
%12 = add nsw i32 %10, -10
%13 = select i1 %11, i32 %12, i32 91
%14 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), i32 %10, i32 %13)
%15 = call i64 @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32* %1)
%16 = load i64, i64* @EOF
%17 = icmp ne i64 %15, %16
%18 = load i32, i32* %1
%19 = icmp ne i32 %18, 0
%20 = select i1 %17, i1 %19, i1 false
br i1 %20, label %9, label %21
21: ; preds = %9, %0
ret i32 0
}