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(){
  int i, j, k;
  int money[3];
  int x;
  int count = 0;
  
  for(i = 0; i < 3; i++)
    scanf("%d", &money[i]);
  
  scanf("%d", &x);
  
  for(i = 0; i <= money[0]; i++){
    for(j = 0; j <= money[1]; j++){
      for(k = 0; k <= money[2]; k++){
        if(x == i * 500 + j * 100 + k * 50)
          count++;
      }
    }
  }
  
  printf("%d\n", count);
  
  return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.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	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -24(%rbp)
	movl	$0, -36(%rbp)
	jmp	.L2
.L3:
	leaq	-20(%rbp), %rdx
	movl	-36(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -36(%rbp)
.L2:
	cmpl	$2, -36(%rbp)
	jle	.L3
	leaq	-40(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -36(%rbp)
	jmp	.L4
.L10:
	movl	$0, -32(%rbp)
	jmp	.L5
.L9:
	movl	$0, -28(%rbp)
	jmp	.L6
.L8:
	movl	-36(%rbp), %eax
	imull	$500, %eax, %edx
	movl	-32(%rbp), %eax
	imull	$100, %eax, %eax
	addl	%eax, %edx
	movl	-28(%rbp), %eax
	imull	$50, %eax, %eax
	addl	%eax, %edx
	movl	-40(%rbp), %eax
	cmpl	%eax, %edx
	jne	.L7
	addl	$1, -24(%rbp)
.L7:
	addl	$1, -28(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L8
	addl	$1, -32(%rbp)
.L5:
	movl	-16(%rbp), %eax
	cmpl	%eax, -32(%rbp)
	jle	.L9
	addl	$1, -36(%rbp)
.L4:
	movl	-20(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L10
	movl	-24(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L12
	call	__stack_chk_fail@PLT
.L12:
	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
.LC1:
	.string	"%d"
.LC3:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC1(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$56, %rsp
	.cfi_def_cfa_offset 112
	movq	%fs:40, %rax
	movq	%rax, 40(%rsp)
	xorl	%eax, %eax
	leaq	28(%rsp), %rsi
	call	__isoc99_scanf@PLT
	leaq	32(%rsp), %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	leaq	36(%rsp), %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	leaq	24(%rsp), %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	28(%rsp), %eax
	testl	%eax, %eax
	js	.L20
	movl	36(%rsp), %esi
	movl	24(%rsp), %r9d
	addl	$1, %eax
	xorl	%r14d, %r14d
	movl	32(%rsp), %r15d
	movl	%eax, 12(%rsp)
	xorl	%edx, %edx
	xorl	%r13d, %r13d
	leal	1(%rsi), %r12d
	movd	%r9d, %xmm7
	movdqa	.LC2(%rip), %xmm5
	movl	%r12d, %edi
	leal	1(%r15), %ebp
	pshufd	$0, %xmm7, %xmm6
	movl	%r12d, %r11d
	shrl	$2, %edi
	andl	$-4, %r11d
	.p2align 4,,10
	.p2align 3
.L3:
	testl	%r15d, %r15d
	js	.L15
	movl	%r14d, %eax
	xorl	%r10d, %r10d
	.p2align 4,,10
	.p2align 3
.L18:
	testl	%esi, %esi
	js	.L17
	cmpl	$6, %esi
	jbe	.L21
	movd	%eax, %xmm7
	movdqa	.LC0(%rip), %xmm3
	xorl	%ecx, %ecx
	pxor	%xmm2, %xmm2
	pshufd	$0, %xmm7, %xmm4
	.p2align 4,,10
	.p2align 3
.L5:
	movdqa	%xmm3, %xmm1
	addl	$1, %ecx
	paddd	%xmm5, %xmm3
	movdqa	%xmm1, %xmm0
	pslld	$1, %xmm0
	paddd	%xmm1, %xmm0
	pslld	$3, %xmm0
	paddd	%xmm1, %xmm0
	pslld	$1, %xmm0
	paddd	%xmm4, %xmm0
	pcmpeqd	%xmm6, %xmm0
	psubd	%xmm0, %xmm2
	cmpl	%ecx, %edi
	jne	.L5
	movdqa	%xmm2, %xmm0
	psrldq	$8, %xmm0
	paddd	%xmm0, %xmm2
	movdqa	%xmm2, %xmm0
	psrldq	$4, %xmm0
	paddd	%xmm0, %xmm2
	movd	%xmm2, %ecx
	addl	%ecx, %edx
	movl	%r11d, %ecx
	cmpl	%r11d, %r12d
	je	.L17
.L4:
	imull	$50, %ecx, %r8d
	leal	(%rax,%r8), %ebx
	cmpl	%r9d, %ebx
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	1(%rcx), %ebx
	cmpl	%esi, %ebx
	jg	.L17
	leal	50(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	2(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	100(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	3(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	150(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	4(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	200(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	5(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	250(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	addl	$6, %ecx
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	cmpl	%ecx, %esi
	jl	.L17
	leal	300(%r8,%rax), %ecx
	cmpl	%ecx, %r9d
	sete	%cl
	movzbl	%cl, %ecx
	addl	%ecx, %edx
.L17:
	addl	$1, %r10d
	addl	$100, %eax
	cmpl	%ebp, %r10d
	jne	.L18
.L15:
	addl	$1, %r13d
	addl	$500, %r14d
	cmpl	12(%rsp), %r13d
	jne	.L3
.L2:
	xorl	%eax, %eax
	leaq	.LC3(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L27
	addq	$56, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L21:
	.cfi_restore_state
	xorl	%ecx, %ecx
	jmp	.L4
.L20:
	xorl	%edx, %edx
	jmp	.L2
.L27:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.long	0
	.long	1
	.long	2
	.long	3
	.align 16
.LC2:
	.long	4
	.long	4
	.long	4
	.long	4
	.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
.LC1:
	.string	"%d"
.LC3:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC1(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$56, %rsp
	.cfi_def_cfa_offset 112
	movq	%fs:40, %rax
	movq	%rax, 40(%rsp)
	xorl	%eax, %eax
	leaq	28(%rsp), %rsi
	call	__isoc99_scanf@PLT
	leaq	32(%rsp), %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	leaq	36(%rsp), %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	leaq	24(%rsp), %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	28(%rsp), %eax
	testl	%eax, %eax
	js	.L20
	movl	36(%rsp), %esi
	movl	24(%rsp), %r9d
	addl	$1, %eax
	xorl	%r14d, %r14d
	movl	32(%rsp), %r15d
	movl	%eax, 12(%rsp)
	xorl	%edx, %edx
	xorl	%r13d, %r13d
	leal	1(%rsi), %r12d
	movd	%r9d, %xmm7
	movdqa	.LC2(%rip), %xmm5
	movl	%r12d, %edi
	leal	1(%r15), %ebp
	pshufd	$0, %xmm7, %xmm6
	movl	%r12d, %r11d
	shrl	$2, %edi
	andl	$-4, %r11d
	.p2align 4,,10
	.p2align 3
.L3:
	testl	%r15d, %r15d
	js	.L15
	movl	%r14d, %eax
	xorl	%r10d, %r10d
	.p2align 4,,10
	.p2align 3
.L18:
	testl	%esi, %esi
	js	.L17
	cmpl	$6, %esi
	jbe	.L21
	movd	%eax, %xmm7
	movdqa	.LC0(%rip), %xmm3
	xorl	%ecx, %ecx
	pxor	%xmm2, %xmm2
	pshufd	$0, %xmm7, %xmm4
	.p2align 4,,10
	.p2align 3
.L5:
	movdqa	%xmm3, %xmm1
	addl	$1, %ecx
	paddd	%xmm5, %xmm3
	movdqa	%xmm1, %xmm0
	pslld	$1, %xmm0
	paddd	%xmm1, %xmm0
	pslld	$3, %xmm0
	paddd	%xmm1, %xmm0
	pslld	$1, %xmm0
	paddd	%xmm4, %xmm0
	pcmpeqd	%xmm6, %xmm0
	psubd	%xmm0, %xmm2
	cmpl	%ecx, %edi
	jne	.L5
	movdqa	%xmm2, %xmm0
	psrldq	$8, %xmm0
	paddd	%xmm0, %xmm2
	movdqa	%xmm2, %xmm0
	psrldq	$4, %xmm0
	paddd	%xmm0, %xmm2
	movd	%xmm2, %ecx
	addl	%ecx, %edx
	movl	%r11d, %ecx
	cmpl	%r11d, %r12d
	je	.L17
.L4:
	imull	$50, %ecx, %r8d
	leal	(%rax,%r8), %ebx
	cmpl	%r9d, %ebx
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	1(%rcx), %ebx
	cmpl	%esi, %ebx
	jg	.L17
	leal	50(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	2(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	100(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	3(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	150(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	4(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	200(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	leal	5(%rcx), %ebx
	cmpl	%ebx, %esi
	jl	.L17
	leal	250(%r8,%rax), %ebx
	cmpl	%ebx, %r9d
	sete	%bl
	addl	$6, %ecx
	movzbl	%bl, %ebx
	addl	%ebx, %edx
	cmpl	%ecx, %esi
	jl	.L17
	leal	300(%r8,%rax), %ecx
	cmpl	%ecx, %r9d
	sete	%cl
	movzbl	%cl, %ecx
	addl	%ecx, %edx
.L17:
	addl	$1, %r10d
	addl	$100, %eax
	cmpl	%ebp, %r10d
	jne	.L18
.L15:
	addl	$1, %r13d
	addl	$500, %r14d
	cmpl	12(%rsp), %r13d
	jne	.L3
.L2:
	xorl	%eax, %eax
	leaq	.LC3(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L27
	addq	$56, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L21:
	.cfi_restore_state
	xorl	%ecx, %ecx
	jmp	.L4
.L20:
	xorl	%edx, %edx
	jmp	.L2
.L27:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.long	0
	.long	1
	.long	2
	.long	3
	.align 16
.LC2:
	.long	4
	.long	4
	.long	4
	.long	4
	.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(){
  int i, j, k;
  int money[3];
  int x;
  int count = 0;
  
  for(i = 0; i < 3; i++)
    scanf("%d", &money[i]);
  
  scanf("%d", &x);
  
  for(i = 0; i <= money[0]; i++){
    for(j = 0; j <= money[1]; j++){
      for(k = 0; k <= money[2]; k++){
        if(x == i * 500 + j * 100 + k * 50)
          count++;
      }
    }
  }
  
  printf("%d\n", count);
  
  return 0;
}
2
2
4
100
 30
40
77
6000
 5
0
0
150
 30
47
77
6000
 5
0
0
0
 2
2
5
100
 2
2
10
100
 30
47
77
10696
 5
0
1
0
 2
0
10
100

2
 293
 0
 319
 1
 2
 2
 0
 1
 1

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(){
  int i, j, k;
  int money[3];
  int x;
  int count = 0;
  
  for(i = 0; i < 3; i++)
    scanf("%d", &money[i]);
  
  scanf("%d", &x);
  
  for(i = 0; i <= money[0]; i++){
    for(j = 0; j <= money[1]; j++){
      for(k = 0; k <= money[2]; k++){
        if(x == i * 500 + j * 100 + k * 50)
          count++;
      }
    }
  }
  
  printf("%d\n", count);
  
  return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.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	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -24(%rbp)
	movl	$0, -36(%rbp)
	jmp	.L2
.L3:
	leaq	-20(%rbp), %rdx
	movl	-36(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -36(%rbp)
.L2:
	cmpl	$2, -36(%rbp)
	jle	.L3
	leaq	-40(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -36(%rbp)
	jmp	.L4
.L10:
	movl	$0, -32(%rbp)
	jmp	.L5
.L9:
	movl	$0, -28(%rbp)
	jmp	.L6
.L8:
	movl	-36(%rbp), %eax
	imull	$500, %eax, %edx
	movl	-32(%rbp), %eax
	imull	$100, %eax, %eax
	addl	%eax, %edx
	movl	-28(%rbp), %eax
	imull	$50, %eax, %eax
	addl	%eax, %edx
	movl	-40(%rbp), %eax
	cmpl	%eax, %edx
	jne	.L7
	addl	$1, -24(%rbp)
.L7:
	addl	$1, -28(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L8
	addl	$1, -32(%rbp)
.L5:
	movl	-16(%rbp), %eax
	cmpl	%eax, -32(%rbp)
	jle	.L9
	addl	$1, -36(%rbp)
.L4:
	movl	-20(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L10
	movl	-24(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L12
	call	__stack_chk_fail@PLT
.L12:
	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	"%d\n"
	.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	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -24(%rbp)
	movl	$0, -36(%rbp)
	jmp	.L2
.L3:
	leaq	-20(%rbp), %rdx
	movl	-36(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -36(%rbp)
.L2:
	cmpl	$2, -36(%rbp)
	jle	.L3
	leaq	-40(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -36(%rbp)
	jmp	.L4
.L10:
	movl	$0, -32(%rbp)
	jmp	.L5
.L9:
	movl	$0, -28(%rbp)
	jmp	.L6
.L8:
	movl	-36(%rbp), %eax
	imull	$500, %eax, %edx
	movl	-32(%rbp), %eax
	imull	$100, %eax, %eax
	addl	%eax, %edx
	movl	-28(%rbp), %eax
	imull	$50, %eax, %eax
	addl	%eax, %edx
	movl	-40(%rbp), %eax
	cmpl	%eax, %edx
	jne	.L7
	addl	$1, -24(%rbp)
.L7:
	addl	$1, -28(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L8
	addl	$1, -32(%rbp)
.L5:
	movl	-16(%rbp), %eax
	cmpl	%eax, -32(%rbp)
	jle	.L9
	addl	$1, -36(%rbp)
.L4:
	movl	-20(%rbp), %eax
	cmpl	%eax, -36(%rbp)
	jle	.L10
	movl	-24(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L12
	call	__stack_chk_fail@PLT
.L12:
	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:
