#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 *, long *);
void main() {
  long int number;
  long int a, b, c, d, e;
  scanf("%d", &number);
  a = number / 10000;
  b = number % 10000 / 1000;
  d = number % 100 / 10;
  e = number % 10;
  if (a == e && b == d) {
    printf("This is a huiwen shu\n");
  } else
    printf("This is not a huiwen shu\n");
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
lea    0xed1(%rip),%rdi
lea    -0x8(%rbp),%rsi
call   1040 <scanf@plt>
mov    -0x8(%rbp),%rax
mov    $0x2710,%ecx
cqto
idiv   %rcx
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
mov    $0x2710,%ecx
cqto
idiv   %rcx
mov    %rdx,%rax
mov    $0x3e8,%ecx
cqto
idiv   %rcx
mov    %rax,-0x18(%rbp)
mov    -0x8(%rbp),%rax
mov    $0x64,%ecx
cqto
idiv   %rcx
mov    %rdx,%rax
mov    $0xa,%ecx
cqto
idiv   %rcx
mov    %rax,-0x28(%rbp)
mov    -0x8(%rbp),%rax
mov    $0xa,%ecx
cqto
idiv   %rcx
mov    %rdx,-0x30(%rbp)
mov    -0x10(%rbp),%rax
cmp    -0x30(%rbp),%rax
jne    11c7 <main+0xa7>
mov    -0x18(%rbp),%rax
cmp    -0x28(%rbp),%rax
jne    11c7 <main+0xa7>
lea    0xe46(%rip),%rdi
call   1030 <printf@plt>
jmp    11d3 <main+0xb3>
lea    0xe4b(%rip),%rdi
call   1030 <printf@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rdi
mov    %rsp,%rsi
call   1040 <scanf@plt>
mov    (%rsp),%rcx
movabs $0x346dc5d63886594b,%rdx
c5 6d 34
mov    %rcx,%rax
imul   %rdx
mov    %rdx,%rsi
movabs $0x6666666666666667,%rdx
66 66 66
mov    %rcx,%rax
imul   %rdx
mov    %rsi,%rax
shr    $0x3f,%rax
sar    $0xb,%rsi
add    %rax,%rsi
mov    %rdx,%rax
shr    $0x3f,%rax
sar    $0x2,%rdx
add    %rax,%rdx
add    %rdx,%rdx
lea    (%rdx,%rdx,4),%rax
mov    %rcx,%rdx
sub    %rax,%rdx
cmp    %rdx,%rsi
jne    11f7 <main+0xd7>
imul   $0x2710,%rsi,%rax
mov    %rcx,%rsi
sub    %rax,%rsi
movabs $0xa3d70a3d70a3d70b,%rdx
0a d7 a3
mov    %rcx,%rax
imul   %rdx
add    %rcx,%rdx
mov    %rdx,%rax
shr    $0x3f,%rax
shr    $0x6,%edx
add    %eax,%edx
imul   $0x64,%edx,%eax
sub    %eax,%ecx
movsbl %cl,%eax
imul   $0x67,%eax,%eax
movzwl %ax,%eax
movswl %ax,%ecx
shr    $0xf,%eax
shr    $0xa,%ecx
add    %al,%cl
movswl %si,%eax
imul   $0xffff8313,%eax,%eax
shr    $0x10,%eax
add    %esi,%eax
movzwl %ax,%eax
movswl %ax,%edx
shr    $0xf,%eax
sar    $0x9,%edx
add    %eax,%edx
movsbl %cl,%eax
cmp    %ax,%dx
jne    11f7 <main+0xd7>
lea    0xe27(%rip),%rdi
jmp    11fe <main+0xde>
lea    0xe05(%rip),%rdi
call   1030 <puts@plt>
pop    %rax
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
@.str.1 = [22 x i8] c"This is a huiwen shu\0A\00"
@.str.2 = [26 x i8] c"This is not a huiwen shu\0A\00"
define void @main() {
%1 = alloca i64
%2 = alloca i64
%3 = alloca i64
%4 = alloca i64
%5 = alloca i64
%6 = alloca i64
%7 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i64* %1)
%8 = load i64, i64* %1
%9 = sdiv i64 %8, 10000
store i64 %9, i64* %2
%10 = load i64, i64* %1
%11 = srem i64 %10, 10000
%12 = sdiv i64 %11, 1000
store i64 %12, i64* %3
%13 = load i64, i64* %1
%14 = srem i64 %13, 100
%15 = sdiv i64 %14, 10
store i64 %15, i64* %5
%16 = load i64, i64* %1
%17 = srem i64 %16, 10
store i64 %17, i64* %6
%18 = load i64, i64* %2
%19 = load i64, i64* %6
%20 = icmp eq i64 %18, %19
br i1 %20, label %21, label %27
21: ; preds = %0
%22 = load i64, i64* %3
%23 = load i64, i64* %5
%24 = icmp eq i64 %22, %23
br i1 %24, label %25, label %27
25: ; preds = %21
%26 = call i32 @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.1, i64 0, i64 0))
br label %29
27: ; preds = %21, %0
%28 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.2, i64 0, i64 0))
br label %29
29: ; preds = %27, %25
ret void
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
@str = [25 x i8] c"This is not a huiwen shu\00"
@str.3 = [21 x i8] c"This is a huiwen shu\00"
define void @main() {
%1 = alloca i64
%2 = bitcast i64* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i64* %1)
%4 = load i64, i64* %1
%5 = sdiv i64 %4, 10000
%6 = srem i64 %4, 10000
%7 = srem i64 %4, 10
%8 = icmp eq i64 %5, %7
br i1 %8, label %9, label %17
9: ; preds = %0
%10 = srem i64 %4, 100
%11 = trunc i64 %10 to i8
%12 = sdiv i8 %11, 10
%13 = trunc i64 %6 to i16
%14 = sdiv i16 %13, 1000
%15 = sext i8 %12 to i16
%16 = icmp eq i16 %14, %15
br i1 %16, label %18, label %17
17: ; preds = %9, %0
br label %18
18: ; preds = %9, %17
%19 = phi i8* [ getelementptr inbounds ([25 x i8], [25 x i8]* @str, i64 0, i64 0), %17 ], [ getelementptr inbounds ([21 x i8], [21 x i8]* @str.3, i64 0, i64 0), %9 ]
%20 = call i32 @puts(i8* dereferenceable(1) %19)
ret void
}