#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 OR3(int);
int /*<<< orphan*/ printf(char *, int);
scalar_t__ scanf(char *, int *);
int main(void) {
  int m, n;
  while (scanf("%d", &n) != EOF && n != 0) {
    scanf("%d", &m);
    printf("%d\n", OR3(m) - OR3(n - 1));
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeba(%rip),%rdi
lea    -0xc(%rbp),%rsi
call   1050 <scanf@plt>
mov    %rax,%rcx
xor    %eax,%eax
mov    0x2e8d(%rip),%rdx
cmp    (%rdx),%rcx
mov    %al,-0xd(%rbp)
je     1171 <main+0x41>
cmpl   $0x0,-0xc(%rbp)
setne  %al
mov    %al,-0xd(%rbp)
mov    -0xd(%rbp),%al
test   $0x1,%al
jne    1181 <main+0x51>
jmp    11bd <main+0x8d>
lea    0xe78(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1050 <scanf@plt>
mov    -0x8(%rbp),%edi
call   1030 <OR3@plt>
mov    %eax,-0x14(%rbp)
mov    -0xc(%rbp),%edi
sub    $0x1,%edi
call   1030 <OR3@plt>
mov    -0x14(%rbp),%esi
sub    %eax,%esi
lea    0xe50(%rip),%rdi
call   1040 <printf@plt>
jmp    113f <main+0xf>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
lea    0xebe(%rip),%rdi
mov    %rsp,%rsi
call   1050 <scanf@plt>
mov    0x2e97(%rip),%r13
cmp    0x0(%r13),%rax
je     11c4 <main+0x94>
cmpl   $0x0,(%rsp)
je     11c4 <main+0x94>
lea    0xe9c(%rip),%rbx
lea    0x4(%rsp),%r14
lea    0xe93(%rip),%r15
mov    %rsp,%r12
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    %rbx,%rdi
mov    %r14,%rsi
call   1050 <scanf@plt>
mov    0x4(%rsp),%edi
call   1030 <OR3@plt>
mov    %eax,%ebp
mov    (%rsp),%edi
add    $0xffffffff,%edi
call   1030 <OR3@plt>
sub    %eax,%ebp
mov    %r15,%rdi
mov    %ebp,%esi
call   1040 <printf@plt>
mov    %rbx,%rdi
mov    %r12,%rsi
call   1050 <scanf@plt>
cmp    0x0(%r13),%rax
je     11c4 <main+0x94>
cmpl   $0x0,(%rsp)
jne    1180 <main+0x50>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

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