Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdio.h>

int main(void){

  int rate;

  scanf("%d",& rate);

  if((400<=rate)&&(rate<=1999)){

  if((400<=rate)&&(rate<=599)){
    printf("8\n");
  }if((600<=rate)&&(rate<=799)){
    printf("7\n");
  }if((800<=rate)&&(rate<=999)){
    printf("6\n");
  }if((1000<=rate)&&(rate<=1199)){
    printf("5\n");
  }if((1200<=rate)&&(rate<=1399)){
    printf("4\n");
  }if((1400<=rate)&&(rate<=1599)){
    printf("3\n");
  }if((1600<=rate)&&(rate<=1799)){
    printf("2\n");
  }if((1800<=rate)&&(rate<=1999)){
    printf("1\n");
  }

  }

  return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"8"
.LC2:
	.string	"7"
.LC3:
	.string	"6"
.LC4:
	.string	"5"
.LC5:
	.string	"4"
.LC6:
	.string	"3"
.LC7:
	.string	"2"
.LC8:
	.string	"1"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-12(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-12(%rbp), %eax
	cmpl	$399, %eax
	jle	.L2
	movl	-12(%rbp), %eax
	cmpl	$1999, %eax
	jg	.L2
	movl	-12(%rbp), %eax
	cmpl	$399, %eax
	jle	.L3
	movl	-12(%rbp), %eax
	cmpl	$599, %eax
	jg	.L3
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L3:
	movl	-12(%rbp), %eax
	cmpl	$599, %eax
	jle	.L4
	movl	-12(%rbp), %eax
	cmpl	$799, %eax
	jg	.L4
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L4:
	movl	-12(%rbp), %eax
	cmpl	$799, %eax
	jle	.L5
	movl	-12(%rbp), %eax
	cmpl	$999, %eax
	jg	.L5
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L5:
	movl	-12(%rbp), %eax
	cmpl	$999, %eax
	jle	.L6
	movl	-12(%rbp), %eax
	cmpl	$1199, %eax
	jg	.L6
	leaq	.LC4(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L6:
	movl	-12(%rbp), %eax
	cmpl	$1199, %eax
	jle	.L7
	movl	-12(%rbp), %eax
	cmpl	$1399, %eax
	jg	.L7
	leaq	.LC5(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L7:
	movl	-12(%rbp), %eax
	cmpl	$1399, %eax
	jle	.L8
	movl	-12(%rbp), %eax
	cmpl	$1599, %eax
	jg	.L8
	leaq	.LC6(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L8:
	movl	-12(%rbp), %eax
	cmpl	$1599, %eax
	jle	.L9
	movl	-12(%rbp), %eax
	cmpl	$1799, %eax
	jg	.L9
	leaq	.LC7(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L9:
	movl	-12(%rbp), %eax
	cmpl	$1799, %eax
	jle	.L2
	movl	-12(%rbp), %eax
	cmpl	$1999, %eax
	jg	.L2
	leaq	.LC8(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L2:
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L11
	call	__stack_chk_fail@PLT
.L11:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
user
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"8"
.LC2:
	.string	"7"
.LC3:
	.string	"6"
.LC4:
	.string	"5"
.LC5:
	.string	"4"
.LC6:
	.string	"3"
.LC7:
	.string	"2"
.LC8:
	.string	"1"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	subq	$24, %rsp
	.cfi_def_cfa_offset 32
	leaq	.LC0(%rip), %rdi
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %eax
	leal	-400(%rax), %edx
	cmpl	$1599, %edx
	ja	.L3
	cmpl	$199, %edx
	jbe	.L15
.L4:
	leal	-600(%rax), %edx
	cmpl	$199, %edx
	jbe	.L16
.L5:
	leal	-800(%rax), %edx
	cmpl	$199, %edx
	jbe	.L17
.L6:
	leal	-1000(%rax), %edx
	cmpl	$199, %edx
	jbe	.L18
.L7:
	leal	-1200(%rax), %edx
	cmpl	$199, %edx
	jbe	.L19
.L8:
	leal	-1400(%rax), %edx
	cmpl	$199, %edx
	jbe	.L20
.L9:
	leal	-1600(%rax), %edx
	cmpl	$199, %edx
	jbe	.L21
.L10:
	subl	$1800, %eax
	cmpl	$199, %eax
	jbe	.L22
.L3:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	xorl	%eax, %eax
	addq	$24, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
.L22:
	.cfi_restore_state
	leaq	.LC8(%rip), %rdi
	call	puts@PLT
	jmp	.L3
.L15:
	leaq	.LC1(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L4
.L16:
	leaq	.LC2(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L5
.L17:
	leaq	.LC3(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L6
.L18:
	leaq	.LC4(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L7
.L19:
	leaq	.LC5(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L8
.L20:
	leaq	.LC6(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L9
.L21:
	leaq	.LC7(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L10
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

rule
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"8"
.LC2:
	.string	"7"
.LC3:
	.string	"6"
.LC4:
	.string	"5"
.LC5:
	.string	"4"
.LC6:
	.string	"3"
.LC7:
	.string	"2"
.LC8:
	.string	"1"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	subq	$24, %rsp
	.cfi_def_cfa_offset 32
	leaq	.LC0(%rip), %rdi
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %eax
	leal	-400(%rax), %edx
	cmpl	$1599, %edx
	ja	.L3
	cmpl	$199, %edx
	jbe	.L15
.L4:
	leal	-600(%rax), %edx
	cmpl	$199, %edx
	jbe	.L16
.L5:
	leal	-800(%rax), %edx
	cmpl	$199, %edx
	jbe	.L17
.L6:
	leal	-1000(%rax), %edx
	cmpl	$199, %edx
	jbe	.L18
.L7:
	leal	-1200(%rax), %edx
	cmpl	$199, %edx
	jbe	.L19
.L8:
	leal	-1400(%rax), %edx
	cmpl	$199, %edx
	jbe	.L20
.L9:
	leal	-1600(%rax), %edx
	cmpl	$199, %edx
	jbe	.L21
.L10:
	subl	$1800, %eax
	cmpl	$199, %eax
	jbe	.L22
.L3:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	xorl	%eax, %eax
	addq	$24, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
.L22:
	.cfi_restore_state
	leaq	.LC8(%rip), %rdi
	call	puts@PLT
	jmp	.L3
.L15:
	leaq	.LC1(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L4
.L16:
	leaq	.LC2(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L5
.L17:
	leaq	.LC3(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L6
.L18:
	leaq	.LC4(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L7
.L19:
	leaq	.LC5(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L8
.L20:
	leaq	.LC6(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L9
.L21:
	leaq	.LC7(%rip), %rdi
	call	puts@PLT
	movl	4(%rsp), %eax
	jmp	.L10
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

#include<stdio.h>

int main(void){

  int rate;

  scanf("%d",& rate);

  if((400<=rate)&&(rate<=1999)){

  if((400<=rate)&&(rate<=599)){
    printf("8\n");
  }if((600<=rate)&&(rate<=799)){
    printf("7\n");
  }if((800<=rate)&&(rate<=999)){
    printf("6\n");
  }if((1000<=rate)&&(rate<=1199)){
    printf("5\n");
  }if((1200<=rate)&&(rate<=1399)){
    printf("4\n");
  }if((1400<=rate)&&(rate<=1599)){
    printf("3\n");
  }if((1600<=rate)&&(rate<=1799)){
    printf("2\n");
  }if((1800<=rate)&&(rate<=1999)){
    printf("1\n");
  }

  }

  return 0;
}

1359
 543
 1855
 609
 982
 1485
 1125
 1764
 554
 417

4
 8
 1
 7
 6
 3
 5
 2
 8
 8

Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdio.h>

int main(void){

  int rate;

  scanf("%d",& rate);

  if((400<=rate)&&(rate<=1999)){

  if((400<=rate)&&(rate<=599)){
    printf("8\n");
  }if((600<=rate)&&(rate<=799)){
    printf("7\n");
  }if((800<=rate)&&(rate<=999)){
    printf("6\n");
  }if((1000<=rate)&&(rate<=1199)){
    printf("5\n");
  }if((1200<=rate)&&(rate<=1399)){
    printf("4\n");
  }if((1400<=rate)&&(rate<=1599)){
    printf("3\n");
  }if((1600<=rate)&&(rate<=1799)){
    printf("2\n");
  }if((1800<=rate)&&(rate<=1999)){
    printf("1\n");
  }

  }

  return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"8"
.LC2:
	.string	"7"
.LC3:
	.string	"6"
.LC4:
	.string	"5"
.LC5:
	.string	"4"
.LC6:
	.string	"3"
.LC7:
	.string	"2"
.LC8:
	.string	"1"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-12(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-12(%rbp), %eax
	cmpl	$399, %eax
	jle	.L2
	movl	-12(%rbp), %eax
	cmpl	$1999, %eax
	jg	.L2
	movl	-12(%rbp), %eax
	cmpl	$399, %eax
	jle	.L3
	movl	-12(%rbp), %eax
	cmpl	$599, %eax
	jg	.L3
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L3:
	movl	-12(%rbp), %eax
	cmpl	$599, %eax
	jle	.L4
	movl	-12(%rbp), %eax
	cmpl	$799, %eax
	jg	.L4
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L4:
	movl	-12(%rbp), %eax
	cmpl	$799, %eax
	jle	.L5
	movl	-12(%rbp), %eax
	cmpl	$999, %eax
	jg	.L5
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L5:
	movl	-12(%rbp), %eax
	cmpl	$999, %eax
	jle	.L6
	movl	-12(%rbp), %eax
	cmpl	$1199, %eax
	jg	.L6
	leaq	.LC4(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L6:
	movl	-12(%rbp), %eax
	cmpl	$1199, %eax
	jle	.L7
	movl	-12(%rbp), %eax
	cmpl	$1399, %eax
	jg	.L7
	leaq	.LC5(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L7:
	movl	-12(%rbp), %eax
	cmpl	$1399, %eax
	jle	.L8
	movl	-12(%rbp), %eax
	cmpl	$1599, %eax
	jg	.L8
	leaq	.LC6(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L8:
	movl	-12(%rbp), %eax
	cmpl	$1599, %eax
	jle	.L9
	movl	-12(%rbp), %eax
	cmpl	$1799, %eax
	jg	.L9
	leaq	.LC7(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L9:
	movl	-12(%rbp), %eax
	cmpl	$1799, %eax
	jle	.L2
	movl	-12(%rbp), %eax
	cmpl	$1999, %eax
	jg	.L2
	leaq	.LC8(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L2:
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L11
	call	__stack_chk_fail@PLT
.L11:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
train
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"8"
.LC2:
	.string	"7"
.LC3:
	.string	"6"
.LC4:
	.string	"5"
.LC5:
	.string	"4"
.LC6:
	.string	"3"
.LC7:
	.string	"2"
.LC8:
	.string	"1"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-12(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-12(%rbp), %eax
	cmpl	$399, %eax
	jle	.L2
	movl	-12(%rbp), %eax
	cmpl	$1999, %eax
	jg	.L2
	movl	-12(%rbp), %eax
	cmpl	$399, %eax
	jle	.L3
	movl	-12(%rbp), %eax
	cmpl	$599, %eax
	jg	.L3
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L3:
	movl	-12(%rbp), %eax
	cmpl	$599, %eax
	jle	.L4
	movl	-12(%rbp), %eax
	cmpl	$799, %eax
	jg	.L4
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L4:
	movl	-12(%rbp), %eax
	cmpl	$799, %eax
	jle	.L5
	movl	-12(%rbp), %eax
	cmpl	$999, %eax
	jg	.L5
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L5:
	movl	-12(%rbp), %eax
	cmpl	$999, %eax
	jle	.L6
	movl	-12(%rbp), %eax
	cmpl	$1199, %eax
	jg	.L6
	leaq	.LC4(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L6:
	movl	-12(%rbp), %eax
	cmpl	$1199, %eax
	jle	.L7
	movl	-12(%rbp), %eax
	cmpl	$1399, %eax
	jg	.L7
	leaq	.LC5(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L7:
	movl	-12(%rbp), %eax
	cmpl	$1399, %eax
	jle	.L8
	movl	-12(%rbp), %eax
	cmpl	$1599, %eax
	jg	.L8
	leaq	.LC6(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L8:
	movl	-12(%rbp), %eax
	cmpl	$1599, %eax
	jle	.L9
	movl	-12(%rbp), %eax
	cmpl	$1799, %eax
	jg	.L9
	leaq	.LC7(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L9:
	movl	-12(%rbp), %eax
	cmpl	$1799, %eax
	jle	.L2
	movl	-12(%rbp), %eax
	cmpl	$1999, %eax
	jg	.L2
	leaq	.LC8(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L2:
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L11
	call	__stack_chk_fail@PLT
.L11:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
