#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 *, int *, int *, int *);
main() {
  int a, b, c, d, x;
  scanf("%d%d%d%d%d", &a, &b, &c, &d, &x);
  if (x <= b && x >= a) {
    printf("x принадлежит 1-ому отрезку\n");
  }
  if (x <= d && x >= c) {
    printf("x принадлежит 2-ому отрезку\n");
  }
  if (x >= a && x <= b && x >= c && x <= d) {
    printf("x принадлежит обоим отрезкам");
  } else {
    printf("x не принадлежит ни одному из отрезков\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
lea    -0x8(%rbp),%rsi
lea    -0xc(%rbp),%rdx
lea    -0x10(%rbp),%rcx
lea    -0x14(%rbp),%r8
lea    -0x18(%rbp),%r9
call   1040 <scanf@plt>
mov    -0x18(%rbp),%eax
cmp    -0xc(%rbp),%eax
jg     1173 <main+0x53>
mov    -0x18(%rbp),%eax
cmp    -0x8(%rbp),%eax
jl     1173 <main+0x53>
lea    0xe9d(%rip),%rdi
call   1030 <printf@plt>
mov    -0x18(%rbp),%eax
cmp    -0x14(%rbp),%eax
jg     1197 <main+0x77>
mov    -0x18(%rbp),%eax
cmp    -0x10(%rbp),%eax
jl     1197 <main+0x77>
lea    0xeab(%rip),%rdi
call   1030 <printf@plt>
mov    -0x18(%rbp),%eax
cmp    -0x8(%rbp),%eax
jl     11d8 <main+0xb8>
mov    -0x18(%rbp),%eax
cmp    -0xc(%rbp),%eax
jg     11d8 <main+0xb8>
mov    -0x18(%rbp),%eax
cmp    -0x10(%rbp),%eax
jl     11d8 <main+0xb8>
mov    -0x18(%rbp),%eax
cmp    -0x14(%rbp),%eax
jg     11d8 <main+0xb8>
lea    0xea1(%rip),%rdi
call   1030 <printf@plt>
jmp    11e4 <main+0xc4>
lea    0xec5(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x18,%rsp
lea    0xec5(%rip),%rdi
lea    0x14(%rsp),%rsi
lea    0x10(%rsp),%rdx
lea    0xc(%rsp),%rcx
lea    0x8(%rsp),%r8
lea    0x4(%rsp),%r9
call   1050 <scanf@plt>
mov    0x4(%rsp),%eax
cmp    0x10(%rsp),%eax
jg     1179 <main+0x49>
cmp    0x14(%rsp),%eax
jl     1179 <main+0x49>
lea    0xf47(%rip),%rdi
call   1030 <puts@plt>
mov    0x4(%rsp),%eax
mov    0x8(%rsp),%ecx
mov    0xc(%rsp),%edx
cmp    %ecx,%eax
jg     11a1 <main+0x71>
cmp    %edx,%eax
jl     11a1 <main+0x71>
lea    0xef6(%rip),%rdi
call   1030 <puts@plt>
mov    0x4(%rsp),%eax
mov    0xc(%rsp),%edx
mov    0x8(%rsp),%ecx
cmp    0x14(%rsp),%eax
jl     11c3 <main+0x93>
cmp    0x10(%rsp),%eax
jg     11c3 <main+0x93>
cmp    %edx,%eax
jl     11c3 <main+0x93>
cmp    %ecx,%eax
jg     11c3 <main+0x93>
lea    0xe4f(%rip),%rdi
call   1040 <printf@plt>
jmp    11cf <main+0x9f>
lea    0xe76(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x18,%rsp
ret

LLVM IR (-O0):
@.str = [11 x i8] c"%d%d%d%d%d\00"
@.str.1 = [50 x i8] c"x \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 1-\D0\BE\D0\BC\D1\83 \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D1\83\0A\00"
@.str.2 = [50 x i8] c"x \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 2-\D0\BE\D0\BC\D1\83 \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D1\83\0A\00"
@.str.3 = [53 x i8] c"x \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 \D0\BE\D0\B1\D0\BE\D0\B8\D0\BC \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D0\B0\D0\BC\00"
@.str.4 = [71 x i8] c"x \D0\BD\D0\B5 \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 \D0\BD\D0\B8 \D0\BE\D0\B4\D0\BD\D0\BE\D0\BC\D1\83 \D0\B8\D0\B7 \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D0\BE\D0\B2\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
store i32 0, i32* %1
%7 = call i32 @scanf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32* %2, i32* %3, i32* %4, i32* %5, i32* %6)
%8 = load i32, i32* %6
%9 = load i32, i32* %3
%10 = icmp sle i32 %8, %9
br i1 %10, label %11, label %17
11: ; preds = %0
%12 = load i32, i32* %6
%13 = load i32, i32* %2
%14 = icmp sge i32 %12, %13
br i1 %14, label %15, label %17
15: ; preds = %11
%16 = call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.1, i64 0, i64 0))
br label %17
17: ; preds = %15, %11, %0
%18 = load i32, i32* %6
%19 = load i32, i32* %5
%20 = icmp sle i32 %18, %19
br i1 %20, label %21, label %27
21: ; preds = %17
%22 = load i32, i32* %6
%23 = load i32, i32* %4
%24 = icmp sge i32 %22, %23
br i1 %24, label %25, label %27
25: ; preds = %21
%26 = call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.2, i64 0, i64 0))
br label %27
27: ; preds = %25, %21, %17
%28 = load i32, i32* %6
%29 = load i32, i32* %2
%30 = icmp sge i32 %28, %29
br i1 %30, label %31, label %45
31: ; preds = %27
%32 = load i32, i32* %6
%33 = load i32, i32* %3
%34 = icmp sle i32 %32, %33
br i1 %34, label %35, label %45
35: ; preds = %31
%36 = load i32, i32* %6
%37 = load i32, i32* %4
%38 = icmp sge i32 %36, %37
br i1 %38, label %39, label %45
39: ; preds = %35
%40 = load i32, i32* %6
%41 = load i32, i32* %5
%42 = icmp sle i32 %40, %41
br i1 %42, label %43, label %45
43: ; preds = %39
%44 = call i32 @printf(i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str.3, i64 0, i64 0))
br label %47
45: ; preds = %39, %35, %31, %27
%46 = call i32 @printf(i8* getelementptr inbounds ([71 x i8], [71 x i8]* @.str.4, i64 0, i64 0))
br label %47
47: ; preds = %45, %43
ret i32 0
}

LLVM IR (-O2):
@.str = [11 x i8] c"%d%d%d%d%d\00"
@.str.3 = [53 x i8] c"x \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 \D0\BE\D0\B1\D0\BE\D0\B8\D0\BC \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D0\B0\D0\BC\00"
@str = [70 x i8] c"x \D0\BD\D0\B5 \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 \D0\BD\D0\B8 \D0\BE\D0\B4\D0\BD\D0\BE\D0\BC\D1\83 \D0\B8\D0\B7 \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D0\BE\D0\B2\00"
@str.5 = [49 x i8] c"x \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 2-\D0\BE\D0\BC\D1\83 \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D1\83\00"
@str.6 = [49 x i8] c"x \D0\BF\D1\80\D0\B8\D0\BD\D0\B0\D0\B4\D0\BB\D0\B5\D0\B6\D0\B8\D1\82 1-\D0\BE\D0\BC\D1\83 \D0\BE\D1\82\D1\80\D0\B5\D0\B7\D0\BA\D1\83\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = bitcast i32* %1 to i8*
%7 = bitcast i32* %2 to i8*
%8 = bitcast i32* %3 to i8*
%9 = bitcast i32* %4 to i8*
%10 = bitcast i32* %5 to i8*
%11 = call i32 @scanf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32* %1, i32* %2, i32* %3, i32* %4, i32* %5)
%12 = load i32, i32* %5
%13 = load i32, i32* %2
%14 = icmp sgt i32 %12, %13
%15 = load i32, i32* %1
%16 = icmp slt i32 %12, %15
%17 = select i1 %14, i1 true, i1 %16
br i1 %17, label %21, label %18
18: ; preds = %0
%19 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @str.6, i64 0, i64 0))
%20 = load i32, i32* %5
br label %21
21: ; preds = %18, %0
%22 = phi i32 [ %20, %18 ], [ %12, %0 ]
%23 = load i32, i32* %4
%24 = icmp sgt i32 %22, %23
%25 = load i32, i32* %3
%26 = icmp slt i32 %22, %25
%27 = select i1 %24, i1 true, i1 %26
br i1 %27, label %33, label %28
28: ; preds = %21
%29 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @str.5, i64 0, i64 0))
%30 = load i32, i32* %5
%31 = load i32, i32* %3
%32 = load i32, i32* %4
br label %33
33: ; preds = %28, %21
%34 = phi i32 [ %32, %28 ], [ %23, %21 ]
%35 = phi i32 [ %31, %28 ], [ %25, %21 ]
%36 = phi i32 [ %30, %28 ], [ %22, %21 ]
%37 = load i32, i32* %1
%38 = icmp slt i32 %36, %37
%39 = load i32, i32* %2
%40 = icmp sgt i32 %36, %39
%41 = select i1 %38, i1 true, i1 %40
%42 = icmp slt i32 %36, %35
%43 = select i1 %41, i1 true, i1 %42
%44 = icmp sgt i32 %36, %34
%45 = select i1 %43, i1 true, i1 %44
br i1 %45, label %48, label %46
46: ; preds = %33
%47 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([53 x i8], [53 x i8]* @.str.3, i64 0, i64 0))
br label %50
48: ; preds = %33
%49 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([70 x i8], [70 x i8]* @str, i64 0, i64 0))
br label %50
50: ; preds = %48, %46
ret i32 0
}