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>
#include<stdlib.h>
#include<math.h>
#include<string.h> 
#define ll unsigned long long
ll factor[300]; 
ll memory[300];
int primefac(ll num){
    int i = 0,sum,n=0;
    while(*(factor+i) != 0){
        sum =1;
        while(num % *(factor+i)==0){
            num /= *(factor+i);
            memory[*(factor+i)] +=1;
        }
        i++;
    }
    return sum;
}


int elast(ll number){    
    ll tmp=0;
    int flag=0;
    *factor = 2;
    for(int i=3;i <= number;i++){
        flag=0;
        for(int j=0;j <= tmp ;j++){
            if(i % (*(factor+j)) == 0){
                flag=1;
                break;
            }
        }
        if(flag)continue;
        tmp += 1;
        *(factor+tmp) = i;
    }
        return tmp+2;
}

ll nCr(int n,int r){
  ll val=1;
  int i;
  if(r==0)return 1;
  for(i=0;i<n-r;i++){
		val *= (n-i);
		val /= (i+1);
	}
  return val;
}

int main(){
    ll three=0,nago=0,nigo=0,igo=0;
    ll five=0,N,i,j,sum=0;
    memset(factor ,0, sizeof(factor));
    memset(memory,0,sizeof(memory));
    scanf("%llu",&N);
    elast(N);
    for(i=1;i<N;i++){
      primefac(i+1);
    }
    for(i=0;i<N;i++){
      if(memory[i]+1>=75)nago++;
      if(memory[i]+1>=25)nigo++;
      if(memory[i]+1>=15)igo++;
      if(memory[i]+1>=5){
        five++;
        three++;
      }
      else if(memory[i]+1>=3){
        three++;
      }
    }
    if(three>=2){
     sum += nCr(five,2)*(three-2);
     sum +=nago;
     sum += nigo*(three-1);
     sum += igo*(five-1);
    }
    printf("%llu",sum);

    return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	factor
	.bss
	.align 32
	.type	factor, @object
	.size	factor, 2400
factor:
	.zero	2400
	.globl	memory
	.align 32
	.type	memory, @object
	.size	memory, 2400
memory:
	.zero	2400
	.text
	.globl	primefac
	.type	primefac, @function
primefac:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, -12(%rbp)
	movl	$0, -4(%rbp)
	jmp	.L2
.L5:
	movl	$1, -8(%rbp)
	jmp	.L3
.L4:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rsi
	movq	-24(%rbp), %rax
	movl	$0, %edx
	divq	%rsi
	movq	%rax, -24(%rbp)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rcx
	leaq	factor(%rip), %rax
	addq	%rcx, %rax
	movq	(%rax), %rax
	leaq	1(%rdx), %rcx
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	%rcx, (%rdx,%rax)
.L3:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rcx
	movq	-24(%rbp), %rax
	movl	$0, %edx
	divq	%rcx
	movq	%rdx, %rax
	testq	%rax, %rax
	je	.L4
	addl	$1, -12(%rbp)
.L2:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	jne	.L5
	movl	-8(%rbp), %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	primefac, .-primefac
	.globl	elast
	.type	elast, @function
elast:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -40(%rbp)
	movq	$0, -8(%rbp)
	movl	$0, -20(%rbp)
	movq	$2, factor(%rip)
	movl	$3, -16(%rbp)
	jmp	.L8
.L15:
	movl	$0, -20(%rbp)
	movl	$0, -12(%rbp)
	jmp	.L9
.L12:
	movl	-16(%rbp), %eax
	cltq
	movl	-12(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	factor(%rip), %rdx
	addq	%rcx, %rdx
	movq	(%rdx), %rcx
	movl	$0, %edx
	divq	%rcx
	movq	%rdx, %rax
	testq	%rax, %rax
	jne	.L10
	movl	$1, -20(%rbp)
	jmp	.L11
.L10:
	addl	$1, -12(%rbp)
.L9:
	movl	-12(%rbp), %eax
	cltq
	cmpq	%rax, -8(%rbp)
	jnb	.L12
.L11:
	cmpl	$0, -20(%rbp)
	jne	.L17
	addq	$1, -8(%rbp)
	movq	-8(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rax, %rdx
	movl	-16(%rbp), %eax
	cltq
	movq	%rax, (%rdx)
	jmp	.L14
.L17:
	nop
.L14:
	addl	$1, -16(%rbp)
.L8:
	movl	-16(%rbp), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jnb	.L15
	movq	-8(%rbp), %rax
	addl	$2, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	elast, .-elast
	.globl	nCr
	.type	nCr, @function
nCr:
.LFB8:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movq	$1, -8(%rbp)
	cmpl	$0, -24(%rbp)
	jne	.L19
	movl	$1, %eax
	jmp	.L20
.L19:
	movl	$0, -12(%rbp)
	jmp	.L21
.L22:
	movl	-20(%rbp), %eax
	subl	-12(%rbp), %eax
	cltq
	movq	-8(%rbp), %rdx
	imulq	%rdx, %rax
	movq	%rax, -8(%rbp)
	movl	-12(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rcx
	movq	-8(%rbp), %rax
	movl	$0, %edx
	divq	%rcx
	movq	%rax, -8(%rbp)
	addl	$1, -12(%rbp)
.L21:
	movl	-20(%rbp), %eax
	subl	-24(%rbp), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L22
	movq	-8(%rbp), %rax
.L20:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	nCr, .-nCr
	.section	.rodata
.LC0:
	.string	"%llu"
	.text
	.globl	main
	.type	main, @function
main:
.LFB9:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$80, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movq	$0, -64(%rbp)
	movq	$0, -56(%rbp)
	movq	$0, -48(%rbp)
	movq	$0, -40(%rbp)
	movq	$0, -32(%rbp)
	movq	$0, -16(%rbp)
	movl	$2400, %edx
	movl	$0, %esi
	leaq	factor(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	movl	$2400, %edx
	movl	$0, %esi
	leaq	memory(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	leaq	-72(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	-72(%rbp), %rax
	movq	%rax, %rdi
	call	elast
	movq	$1, -24(%rbp)
	jmp	.L24
.L25:
	movq	-24(%rbp), %rax
	addq	$1, %rax
	movq	%rax, %rdi
	call	primefac
	addq	$1, -24(%rbp)
.L24:
	movq	-72(%rbp), %rax
	cmpq	%rax, -24(%rbp)
	jb	.L25
	movq	$0, -24(%rbp)
	jmp	.L26
.L32:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$74, %rax
	jbe	.L27
	addq	$1, -56(%rbp)
.L27:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$24, %rax
	jbe	.L28
	addq	$1, -48(%rbp)
.L28:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$14, %rax
	jbe	.L29
	addq	$1, -40(%rbp)
.L29:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$4, %rax
	jbe	.L30
	addq	$1, -32(%rbp)
	addq	$1, -64(%rbp)
	jmp	.L31
.L30:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$2, %rax
	jbe	.L31
	addq	$1, -64(%rbp)
.L31:
	addq	$1, -24(%rbp)
.L26:
	movq	-72(%rbp), %rax
	cmpq	%rax, -24(%rbp)
	jb	.L32
	cmpq	$1, -64(%rbp)
	jbe	.L33
	movq	-32(%rbp), %rax
	movl	$2, %esi
	movl	%eax, %edi
	call	nCr
	movq	-64(%rbp), %rdx
	subq	$2, %rdx
	imulq	%rdx, %rax
	addq	%rax, -16(%rbp)
	movq	-56(%rbp), %rax
	addq	%rax, -16(%rbp)
	movq	-64(%rbp), %rax
	subq	$1, %rax
	imulq	-48(%rbp), %rax
	addq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	subq	$1, %rax
	imulq	-40(%rbp), %rax
	addq	%rax, -16(%rbp)
.L33:
	movq	-16(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L35
	call	__stack_chk_fail@PLT
.L35:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.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
	.p2align 4
	.globl	primefac
	.type	primefac, @function
primefac:
.LFB51:
	.cfi_startproc
	endbr64
	movq	factor(%rip), %rcx
	leaq	8+factor(%rip), %r9
	leaq	memory(%rip), %r10
	testq	%rcx, %rcx
	je	.L2
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rdi, %rax
	xorl	%edx, %edx
	divq	%rcx
	testq	%rdx, %rdx
	jne	.L6
	movq	(%r10,%rcx,8), %rax
	leaq	1(%rax), %rsi
	.p2align 4,,10
	.p2align 3
.L4:
	movq	%rdi, %rax
	xorl	%edx, %edx
	movq	%rsi, %r8
	addq	$1, %rsi
	divq	%rcx
	xorl	%edx, %edx
	movq	%rax, %rdi
	divq	%rcx
	testq	%rdx, %rdx
	je	.L4
	movq	%r8, (%r10,%rcx,8)
.L6:
	movq	(%r9), %rcx
	addq	$8, %r9
	testq	%rcx, %rcx
	jne	.L3
.L2:
	movl	$1, %eax
	ret
	.cfi_endproc
.LFE51:
	.size	primefac, .-primefac
	.p2align 4
	.globl	elast
	.type	elast, @function
elast:
.LFB52:
	.cfi_startproc
	endbr64
	xorl	%r9d, %r9d
	movl	$3, %esi
	movq	$2, factor(%rip)
	leaq	factor(%rip), %r8
	cmpq	$2, %rdi
	jbe	.L30
	.p2align 4,,10
	.p2align 3
.L17:
	xorl	%ecx, %ecx
	jmp	.L20
	.p2align 4,,10
	.p2align 3
.L32:
	addq	$1, %rcx
	cmpq	%rcx, %r9
	jb	.L31
.L20:
	movq	%rsi, %rax
	xorl	%edx, %edx
	divq	(%r8,%rcx,8)
	testq	%rdx, %rdx
	jne	.L32
	leaq	1(%rsi), %rax
	cmpq	%rsi, %rdi
	je	.L33
.L23:
	movq	%rax, %rsi
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L31:
	addq	$1, %r9
	leaq	1(%rsi), %rax
	movq	%rsi, (%r8,%r9,8)
	cmpq	%rsi, %rdi
	jne	.L23
.L33:
	leal	2(%r9), %eax
	ret
.L30:
	movl	$2, %eax
	ret
	.cfi_endproc
.LFE52:
	.size	elast, .-elast
	.p2align 4
	.globl	nCr
	.type	nCr, @function
nCr:
.LFB53:
	.cfi_startproc
	endbr64
	movl	$1, %eax
	testl	%esi, %esi
	je	.L34
	movl	%edi, %edx
	subl	%esi, %edx
	testl	%edx, %edx
	jle	.L34
	movslq	%edi, %rdi
	leal	1(%rdx), %r8d
	movl	$1, %ecx
	leaq	1(%rdi), %rsi
	.p2align 4,,10
	.p2align 3
.L36:
	movq	%rsi, %rdx
	subq	%rcx, %rdx
	imulq	%rdx, %rax
	xorl	%edx, %edx
	divq	%rcx
	addq	$1, %rcx
	cmpq	%rcx, %r8
	jne	.L36
.L34:
	ret
	.cfi_endproc
.LFE53:
	.size	nCr, .-nCr
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%llu"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB54:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	factor(%rip), %rdx
	movl	$300, %ecx
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	movq	%rdx, %rdi
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	memory(%rip), %rbx
	subq	$16, %rsp
	.cfi_def_cfa_offset 48
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %rsi
	rep stosq
	movl	$300, %ecx
	movq	%rbx, %rdi
	rep stosq
	movq	%rbp, %rdi
	call	__isoc99_scanf@PLT
	movq	(%rsp), %rdi
	call	elast
	movq	(%rsp), %r11
	cmpq	$1, %r11
	jbe	.L42
	movq	factor(%rip), %r12
	testq	%r12, %r12
	je	.L50
	movl	$1, %r10d
	.p2align 4,,10
	.p2align 3
.L46:
	addq	$1, %r10
	leaq	8+factor(%rip), %r9
	movq	%r12, %rsi
	movq	%r10, %rcx
	.p2align 4,,10
	.p2align 3
.L44:
	movq	%rcx, %rax
	xorl	%edx, %edx
	divq	%rsi
	testq	%rdx, %rdx
	jne	.L48
	movq	(%rbx,%rsi,8), %rax
	leaq	1(%rax), %rdi
	.p2align 4,,10
	.p2align 3
.L45:
	movq	%rcx, %rax
	xorl	%edx, %edx
	movq	%rdi, %r8
	addq	$1, %rdi
	divq	%rsi
	xorl	%edx, %edx
	movq	%rax, %rcx
	divq	%rsi
	testq	%rdx, %rdx
	je	.L45
	movq	%r8, (%rbx,%rsi,8)
.L48:
	movq	(%r9), %rsi
	addq	$8, %r9
	testq	%rsi, %rsi
	jne	.L44
	cmpq	%r11, %r10
	jne	.L46
.L50:
	xorl	%edx, %edx
	xorl	%edi, %edi
	xorl	%r9d, %r9d
	xorl	%r10d, %r10d
	xorl	%r8d, %r8d
	xorl	%esi, %esi
	jmp	.L49
.L73:
	addq	$1, %r8
.L53:
	addq	$1, %r10
.L54:
	addq	$1, %r9
.L55:
	addq	$1, %rdx
	addq	$1, %rdi
	addq	$1, %rsi
	cmpq	%r11, %rdx
	jnb	.L72
.L49:
	movq	(%rbx,%rdx,8), %rax
	addq	$1, %rax
	cmpq	$74, %rax
	ja	.L73
	cmpq	$24, %rax
	ja	.L53
	cmpq	$14, %rax
	ja	.L54
	cmpq	$4, %rax
	ja	.L55
	cmpq	$3, %rax
	sbbq	$-1, %rsi
	addq	$1, %rdx
	cmpq	%r11, %rdx
	jb	.L49
.L72:
	cmpq	$1, %rsi
	jbe	.L57
	movslq	%edi, %r11
	cmpl	$2, %edi
	jle	.L61
	leal	-3(%rdi), %ebx
	movl	$1, %ecx
	movl	$1, %eax
	addq	$1, %r11
	addq	$2, %rbx
.L59:
	movq	%r11, %rdx
	subq	%rcx, %rdx
	imulq	%rdx, %rax
	xorl	%edx, %edx
	divq	%rcx
	addq	$1, %rcx
	cmpq	%rcx, %rbx
	jne	.L59
.L58:
	leaq	-1(%rsi), %rdx
	subq	$2, %rsi
	movq	%rdx, %rcx
	imulq	%rsi, %rax
	leaq	-1(%rdi), %rdx
	imulq	%r10, %rcx
	imulq	%r9, %rdx
	addq	%rcx, %rdx
	addq	%r8, %rdx
	addq	%rax, %rdx
.L51:
	xorl	%eax, %eax
	movq	%rbp, %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L74
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L42:
	.cfi_restore_state
	testq	%r11, %r11
	jne	.L50
.L57:
	xorl	%edx, %edx
	jmp	.L51
.L61:
	movl	$1, %eax
	jmp	.L58
.L74:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE54:
	.size	main, .-main
	.globl	memory
	.bss
	.align 32
	.type	memory, @object
	.size	memory, 2400
memory:
	.zero	2400
	.globl	factor
	.align 32
	.type	factor, @object
	.size	factor, 2400
factor:
	.zero	2400
	.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
	.p2align 4
	.globl	primefac
	.type	primefac, @function
primefac:
.LFB51:
	.cfi_startproc
	endbr64
	movq	factor(%rip), %rcx
	leaq	8+factor(%rip), %r9
	leaq	memory(%rip), %r10
	testq	%rcx, %rcx
	je	.L2
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rdi, %rax
	xorl	%edx, %edx
	divq	%rcx
	testq	%rdx, %rdx
	jne	.L6
	movq	(%r10,%rcx,8), %rax
	leaq	1(%rax), %rsi
	.p2align 4,,10
	.p2align 3
.L4:
	movq	%rdi, %rax
	xorl	%edx, %edx
	movq	%rsi, %r8
	addq	$1, %rsi
	divq	%rcx
	xorl	%edx, %edx
	movq	%rax, %rdi
	divq	%rcx
	testq	%rdx, %rdx
	je	.L4
	movq	%r8, (%r10,%rcx,8)
.L6:
	movq	(%r9), %rcx
	addq	$8, %r9
	testq	%rcx, %rcx
	jne	.L3
.L2:
	movl	$1, %eax
	ret
	.cfi_endproc
.LFE51:
	.size	primefac, .-primefac
	.p2align 4
	.globl	elast
	.type	elast, @function
elast:
.LFB52:
	.cfi_startproc
	endbr64
	xorl	%r9d, %r9d
	movl	$3, %esi
	movq	$2, factor(%rip)
	leaq	factor(%rip), %r8
	cmpq	$2, %rdi
	jbe	.L30
	.p2align 4,,10
	.p2align 3
.L17:
	xorl	%ecx, %ecx
	jmp	.L20
	.p2align 4,,10
	.p2align 3
.L32:
	addq	$1, %rcx
	cmpq	%rcx, %r9
	jb	.L31
.L20:
	movq	%rsi, %rax
	xorl	%edx, %edx
	divq	(%r8,%rcx,8)
	testq	%rdx, %rdx
	jne	.L32
	leaq	1(%rsi), %rax
	cmpq	%rsi, %rdi
	je	.L33
.L23:
	movq	%rax, %rsi
	jmp	.L17
	.p2align 4,,10
	.p2align 3
.L31:
	addq	$1, %r9
	leaq	1(%rsi), %rax
	movq	%rsi, (%r8,%r9,8)
	cmpq	%rsi, %rdi
	jne	.L23
.L33:
	leal	2(%r9), %eax
	ret
.L30:
	movl	$2, %eax
	ret
	.cfi_endproc
.LFE52:
	.size	elast, .-elast
	.p2align 4
	.globl	nCr
	.type	nCr, @function
nCr:
.LFB53:
	.cfi_startproc
	endbr64
	movl	$1, %eax
	testl	%esi, %esi
	je	.L34
	movl	%edi, %edx
	subl	%esi, %edx
	testl	%edx, %edx
	jle	.L34
	movslq	%edi, %rdi
	leal	1(%rdx), %r8d
	movl	$1, %ecx
	leaq	1(%rdi), %rsi
	.p2align 4,,10
	.p2align 3
.L36:
	movq	%rsi, %rdx
	subq	%rcx, %rdx
	imulq	%rdx, %rax
	xorl	%edx, %edx
	divq	%rcx
	addq	$1, %rcx
	cmpq	%rcx, %r8
	jne	.L36
.L34:
	ret
	.cfi_endproc
.LFE53:
	.size	nCr, .-nCr
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%llu"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB54:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	factor(%rip), %rdx
	movl	$300, %ecx
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	movq	%rdx, %rdi
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	memory(%rip), %rbx
	subq	$16, %rsp
	.cfi_def_cfa_offset 48
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %rsi
	rep stosq
	movl	$300, %ecx
	movq	%rbx, %rdi
	rep stosq
	movq	%rbp, %rdi
	call	__isoc99_scanf@PLT
	movq	(%rsp), %rdi
	call	elast
	movq	(%rsp), %r11
	cmpq	$1, %r11
	jbe	.L42
	movq	factor(%rip), %r12
	testq	%r12, %r12
	je	.L50
	movl	$1, %r10d
	.p2align 4,,10
	.p2align 3
.L46:
	addq	$1, %r10
	leaq	8+factor(%rip), %r9
	movq	%r12, %rsi
	movq	%r10, %rcx
	.p2align 4,,10
	.p2align 3
.L44:
	movq	%rcx, %rax
	xorl	%edx, %edx
	divq	%rsi
	testq	%rdx, %rdx
	jne	.L48
	movq	(%rbx,%rsi,8), %rax
	leaq	1(%rax), %rdi
	.p2align 4,,10
	.p2align 3
.L45:
	movq	%rcx, %rax
	xorl	%edx, %edx
	movq	%rdi, %r8
	addq	$1, %rdi
	divq	%rsi
	xorl	%edx, %edx
	movq	%rax, %rcx
	divq	%rsi
	testq	%rdx, %rdx
	je	.L45
	movq	%r8, (%rbx,%rsi,8)
.L48:
	movq	(%r9), %rsi
	addq	$8, %r9
	testq	%rsi, %rsi
	jne	.L44
	cmpq	%r11, %r10
	jne	.L46
.L50:
	xorl	%edx, %edx
	xorl	%edi, %edi
	xorl	%r9d, %r9d
	xorl	%r10d, %r10d
	xorl	%r8d, %r8d
	xorl	%esi, %esi
	jmp	.L49
.L73:
	addq	$1, %r8
.L53:
	addq	$1, %r10
.L54:
	addq	$1, %r9
.L55:
	addq	$1, %rdx
	addq	$1, %rdi
	addq	$1, %rsi
	cmpq	%r11, %rdx
	jnb	.L72
.L49:
	movq	(%rbx,%rdx,8), %rax
	addq	$1, %rax
	cmpq	$74, %rax
	ja	.L73
	cmpq	$24, %rax
	ja	.L53
	cmpq	$14, %rax
	ja	.L54
	cmpq	$4, %rax
	ja	.L55
	cmpq	$3, %rax
	sbbq	$-1, %rsi
	addq	$1, %rdx
	cmpq	%r11, %rdx
	jb	.L49
.L72:
	cmpq	$1, %rsi
	jbe	.L57
	movslq	%edi, %r11
	cmpl	$2, %edi
	jle	.L61
	leal	-3(%rdi), %ebx
	movl	$1, %ecx
	movl	$1, %eax
	addq	$1, %r11
	addq	$2, %rbx
.L59:
	movq	%r11, %rdx
	subq	%rcx, %rdx
	imulq	%rdx, %rax
	xorl	%edx, %edx
	divq	%rcx
	addq	$1, %rcx
	cmpq	%rcx, %rbx
	jne	.L59
.L58:
	leaq	-1(%rsi), %rdx
	subq	$2, %rsi
	movq	%rdx, %rcx
	imulq	%rsi, %rax
	leaq	-1(%rdi), %rdx
	imulq	%r10, %rcx
	imulq	%r9, %rdx
	addq	%rcx, %rdx
	addq	%r8, %rdx
	addq	%rax, %rdx
.L51:
	xorl	%eax, %eax
	movq	%rbp, %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L74
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L42:
	.cfi_restore_state
	testq	%r11, %r11
	jne	.L50
.L57:
	xorl	%edx, %edx
	jmp	.L51
.L61:
	movl	$1, %eax
	jmp	.L58
.L74:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE54:
	.size	main, .-main
	.globl	memory
	.bss
	.align 32
	.type	memory, @object
	.size	memory, 2400
memory:
	.zero	2400
	.globl	factor
	.align 32
	.type	factor, @object
	.size	factor, 2400
factor:
	.zero	2400
	.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>
#include<stdlib.h>
#include<math.h>
#include<string.h> 
#define ll unsigned long long
ll factor[300]; 
ll memory[300];
int primefac(ll num){
    int i = 0,sum,n=0;
    while(*(factor+i) != 0){
        sum =1;
        while(num % *(factor+i)==0){
            num /= *(factor+i);
            memory[*(factor+i)] +=1;
        }
        i++;
    }
    return sum;
}


int elast(ll number){    
    ll tmp=0;
    int flag=0;
    *factor = 2;
    for(int i=3;i <= number;i++){
        flag=0;
        for(int j=0;j <= tmp ;j++){
            if(i % (*(factor+j)) == 0){
                flag=1;
                break;
            }
        }
        if(flag)continue;
        tmp += 1;
        *(factor+tmp) = i;
    }
        return tmp+2;
}

ll nCr(int n,int r){
  ll val=1;
  int i;
  if(r==0)return 1;
  for(i=0;i<n-r;i++){
		val *= (n-i);
		val /= (i+1);
	}
  return val;
}

int main(){
    ll three=0,nago=0,nigo=0,igo=0;
    ll five=0,N,i,j,sum=0;
    memset(factor ,0, sizeof(factor));
    memset(memory,0,sizeof(memory));
    scanf("%llu",&N);
    elast(N);
    for(i=1;i<N;i++){
      primefac(i+1);
    }
    for(i=0;i<N;i++){
      if(memory[i]+1>=75)nago++;
      if(memory[i]+1>=25)nigo++;
      if(memory[i]+1>=15)igo++;
      if(memory[i]+1>=5){
        five++;
        three++;
      }
      else if(memory[i]+1>=3){
        three++;
      }
    }
    if(three>=2){
     sum += nCr(five,2)*(three-2);
     sum +=nago;
     sum += nigo*(three-1);
     sum += igo*(five-1);
    }
    printf("%llu",sum);

    return 0;
}

11
 4
 17
 20
 36
 25
 14
 29
 30
 46

1 0 3 8 42 11 2 32 35 86
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>
#include<stdlib.h>
#include<math.h>
#include<string.h> 
#define ll unsigned long long
ll factor[300]; 
ll memory[300];
int primefac(ll num){
    int i = 0,sum,n=0;
    while(*(factor+i) != 0){
        sum =1;
        while(num % *(factor+i)==0){
            num /= *(factor+i);
            memory[*(factor+i)] +=1;
        }
        i++;
    }
    return sum;
}


int elast(ll number){    
    ll tmp=0;
    int flag=0;
    *factor = 2;
    for(int i=3;i <= number;i++){
        flag=0;
        for(int j=0;j <= tmp ;j++){
            if(i % (*(factor+j)) == 0){
                flag=1;
                break;
            }
        }
        if(flag)continue;
        tmp += 1;
        *(factor+tmp) = i;
    }
        return tmp+2;
}

ll nCr(int n,int r){
  ll val=1;
  int i;
  if(r==0)return 1;
  for(i=0;i<n-r;i++){
		val *= (n-i);
		val /= (i+1);
	}
  return val;
}

int main(){
    ll three=0,nago=0,nigo=0,igo=0;
    ll five=0,N,i,j,sum=0;
    memset(factor ,0, sizeof(factor));
    memset(memory,0,sizeof(memory));
    scanf("%llu",&N);
    elast(N);
    for(i=1;i<N;i++){
      primefac(i+1);
    }
    for(i=0;i<N;i++){
      if(memory[i]+1>=75)nago++;
      if(memory[i]+1>=25)nigo++;
      if(memory[i]+1>=15)igo++;
      if(memory[i]+1>=5){
        five++;
        three++;
      }
      else if(memory[i]+1>=3){
        three++;
      }
    }
    if(three>=2){
     sum += nCr(five,2)*(three-2);
     sum +=nago;
     sum += nigo*(three-1);
     sum += igo*(five-1);
    }
    printf("%llu",sum);

    return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	factor
	.bss
	.align 32
	.type	factor, @object
	.size	factor, 2400
factor:
	.zero	2400
	.globl	memory
	.align 32
	.type	memory, @object
	.size	memory, 2400
memory:
	.zero	2400
	.text
	.globl	primefac
	.type	primefac, @function
primefac:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, -12(%rbp)
	movl	$0, -4(%rbp)
	jmp	.L2
.L5:
	movl	$1, -8(%rbp)
	jmp	.L3
.L4:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rsi
	movq	-24(%rbp), %rax
	movl	$0, %edx
	divq	%rsi
	movq	%rax, -24(%rbp)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rcx
	leaq	factor(%rip), %rax
	addq	%rcx, %rax
	movq	(%rax), %rax
	leaq	1(%rdx), %rcx
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	%rcx, (%rdx,%rax)
.L3:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rcx
	movq	-24(%rbp), %rax
	movl	$0, %edx
	divq	%rcx
	movq	%rdx, %rax
	testq	%rax, %rax
	je	.L4
	addl	$1, -12(%rbp)
.L2:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	jne	.L5
	movl	-8(%rbp), %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	primefac, .-primefac
	.globl	elast
	.type	elast, @function
elast:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -40(%rbp)
	movq	$0, -8(%rbp)
	movl	$0, -20(%rbp)
	movq	$2, factor(%rip)
	movl	$3, -16(%rbp)
	jmp	.L8
.L15:
	movl	$0, -20(%rbp)
	movl	$0, -12(%rbp)
	jmp	.L9
.L12:
	movl	-16(%rbp), %eax
	cltq
	movl	-12(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	factor(%rip), %rdx
	addq	%rcx, %rdx
	movq	(%rdx), %rcx
	movl	$0, %edx
	divq	%rcx
	movq	%rdx, %rax
	testq	%rax, %rax
	jne	.L10
	movl	$1, -20(%rbp)
	jmp	.L11
.L10:
	addl	$1, -12(%rbp)
.L9:
	movl	-12(%rbp), %eax
	cltq
	cmpq	%rax, -8(%rbp)
	jnb	.L12
.L11:
	cmpl	$0, -20(%rbp)
	jne	.L17
	addq	$1, -8(%rbp)
	movq	-8(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rax, %rdx
	movl	-16(%rbp), %eax
	cltq
	movq	%rax, (%rdx)
	jmp	.L14
.L17:
	nop
.L14:
	addl	$1, -16(%rbp)
.L8:
	movl	-16(%rbp), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jnb	.L15
	movq	-8(%rbp), %rax
	addl	$2, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	elast, .-elast
	.globl	nCr
	.type	nCr, @function
nCr:
.LFB8:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movq	$1, -8(%rbp)
	cmpl	$0, -24(%rbp)
	jne	.L19
	movl	$1, %eax
	jmp	.L20
.L19:
	movl	$0, -12(%rbp)
	jmp	.L21
.L22:
	movl	-20(%rbp), %eax
	subl	-12(%rbp), %eax
	cltq
	movq	-8(%rbp), %rdx
	imulq	%rdx, %rax
	movq	%rax, -8(%rbp)
	movl	-12(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rcx
	movq	-8(%rbp), %rax
	movl	$0, %edx
	divq	%rcx
	movq	%rax, -8(%rbp)
	addl	$1, -12(%rbp)
.L21:
	movl	-20(%rbp), %eax
	subl	-24(%rbp), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L22
	movq	-8(%rbp), %rax
.L20:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	nCr, .-nCr
	.section	.rodata
.LC0:
	.string	"%llu"
	.text
	.globl	main
	.type	main, @function
main:
.LFB9:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$80, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movq	$0, -64(%rbp)
	movq	$0, -56(%rbp)
	movq	$0, -48(%rbp)
	movq	$0, -40(%rbp)
	movq	$0, -32(%rbp)
	movq	$0, -16(%rbp)
	movl	$2400, %edx
	movl	$0, %esi
	leaq	factor(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	movl	$2400, %edx
	movl	$0, %esi
	leaq	memory(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	leaq	-72(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	-72(%rbp), %rax
	movq	%rax, %rdi
	call	elast
	movq	$1, -24(%rbp)
	jmp	.L24
.L25:
	movq	-24(%rbp), %rax
	addq	$1, %rax
	movq	%rax, %rdi
	call	primefac
	addq	$1, -24(%rbp)
.L24:
	movq	-72(%rbp), %rax
	cmpq	%rax, -24(%rbp)
	jb	.L25
	movq	$0, -24(%rbp)
	jmp	.L26
.L32:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$74, %rax
	jbe	.L27
	addq	$1, -56(%rbp)
.L27:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$24, %rax
	jbe	.L28
	addq	$1, -48(%rbp)
.L28:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$14, %rax
	jbe	.L29
	addq	$1, -40(%rbp)
.L29:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$4, %rax
	jbe	.L30
	addq	$1, -32(%rbp)
	addq	$1, -64(%rbp)
	jmp	.L31
.L30:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$2, %rax
	jbe	.L31
	addq	$1, -64(%rbp)
.L31:
	addq	$1, -24(%rbp)
.L26:
	movq	-72(%rbp), %rax
	cmpq	%rax, -24(%rbp)
	jb	.L32
	cmpq	$1, -64(%rbp)
	jbe	.L33
	movq	-32(%rbp), %rax
	movl	$2, %esi
	movl	%eax, %edi
	call	nCr
	movq	-64(%rbp), %rdx
	subq	$2, %rdx
	imulq	%rdx, %rax
	addq	%rax, -16(%rbp)
	movq	-56(%rbp), %rax
	addq	%rax, -16(%rbp)
	movq	-64(%rbp), %rax
	subq	$1, %rax
	imulq	-48(%rbp), %rax
	addq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	subq	$1, %rax
	imulq	-40(%rbp), %rax
	addq	%rax, -16(%rbp)
.L33:
	movq	-16(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L35
	call	__stack_chk_fail@PLT
.L35:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.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
	.globl	factor
	.bss
	.align 32
	.type	factor, @object
	.size	factor, 2400
factor:
	.zero	2400
	.globl	memory
	.align 32
	.type	memory, @object
	.size	memory, 2400
memory:
	.zero	2400
	.text
	.globl	primefac
	.type	primefac, @function
primefac:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, -12(%rbp)
	movl	$0, -4(%rbp)
	jmp	.L2
.L5:
	movl	$1, -8(%rbp)
	jmp	.L3
.L4:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rsi
	movq	-24(%rbp), %rax
	movl	$0, %edx
	divq	%rsi
	movq	%rax, -24(%rbp)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rcx
	leaq	factor(%rip), %rax
	addq	%rcx, %rax
	movq	(%rax), %rax
	leaq	1(%rdx), %rcx
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	%rcx, (%rdx,%rax)
.L3:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rcx
	movq	-24(%rbp), %rax
	movl	$0, %edx
	divq	%rcx
	movq	%rdx, %rax
	testq	%rax, %rax
	je	.L4
	addl	$1, -12(%rbp)
.L2:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rdx, %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	jne	.L5
	movl	-8(%rbp), %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	primefac, .-primefac
	.globl	elast
	.type	elast, @function
elast:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -40(%rbp)
	movq	$0, -8(%rbp)
	movl	$0, -20(%rbp)
	movq	$2, factor(%rip)
	movl	$3, -16(%rbp)
	jmp	.L8
.L15:
	movl	$0, -20(%rbp)
	movl	$0, -12(%rbp)
	jmp	.L9
.L12:
	movl	-16(%rbp), %eax
	cltq
	movl	-12(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	factor(%rip), %rdx
	addq	%rcx, %rdx
	movq	(%rdx), %rcx
	movl	$0, %edx
	divq	%rcx
	movq	%rdx, %rax
	testq	%rax, %rax
	jne	.L10
	movl	$1, -20(%rbp)
	jmp	.L11
.L10:
	addl	$1, -12(%rbp)
.L9:
	movl	-12(%rbp), %eax
	cltq
	cmpq	%rax, -8(%rbp)
	jnb	.L12
.L11:
	cmpl	$0, -20(%rbp)
	jne	.L17
	addq	$1, -8(%rbp)
	movq	-8(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	factor(%rip), %rax
	addq	%rax, %rdx
	movl	-16(%rbp), %eax
	cltq
	movq	%rax, (%rdx)
	jmp	.L14
.L17:
	nop
.L14:
	addl	$1, -16(%rbp)
.L8:
	movl	-16(%rbp), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jnb	.L15
	movq	-8(%rbp), %rax
	addl	$2, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	elast, .-elast
	.globl	nCr
	.type	nCr, @function
nCr:
.LFB8:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movq	$1, -8(%rbp)
	cmpl	$0, -24(%rbp)
	jne	.L19
	movl	$1, %eax
	jmp	.L20
.L19:
	movl	$0, -12(%rbp)
	jmp	.L21
.L22:
	movl	-20(%rbp), %eax
	subl	-12(%rbp), %eax
	cltq
	movq	-8(%rbp), %rdx
	imulq	%rdx, %rax
	movq	%rax, -8(%rbp)
	movl	-12(%rbp), %eax
	addl	$1, %eax
	movslq	%eax, %rcx
	movq	-8(%rbp), %rax
	movl	$0, %edx
	divq	%rcx
	movq	%rax, -8(%rbp)
	addl	$1, -12(%rbp)
.L21:
	movl	-20(%rbp), %eax
	subl	-24(%rbp), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L22
	movq	-8(%rbp), %rax
.L20:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	nCr, .-nCr
	.section	.rodata
.LC0:
	.string	"%llu"
	.text
	.globl	main
	.type	main, @function
main:
.LFB9:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$80, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movq	$0, -64(%rbp)
	movq	$0, -56(%rbp)
	movq	$0, -48(%rbp)
	movq	$0, -40(%rbp)
	movq	$0, -32(%rbp)
	movq	$0, -16(%rbp)
	movl	$2400, %edx
	movl	$0, %esi
	leaq	factor(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	movl	$2400, %edx
	movl	$0, %esi
	leaq	memory(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	leaq	-72(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	-72(%rbp), %rax
	movq	%rax, %rdi
	call	elast
	movq	$1, -24(%rbp)
	jmp	.L24
.L25:
	movq	-24(%rbp), %rax
	addq	$1, %rax
	movq	%rax, %rdi
	call	primefac
	addq	$1, -24(%rbp)
.L24:
	movq	-72(%rbp), %rax
	cmpq	%rax, -24(%rbp)
	jb	.L25
	movq	$0, -24(%rbp)
	jmp	.L26
.L32:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$74, %rax
	jbe	.L27
	addq	$1, -56(%rbp)
.L27:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$24, %rax
	jbe	.L28
	addq	$1, -48(%rbp)
.L28:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$14, %rax
	jbe	.L29
	addq	$1, -40(%rbp)
.L29:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$4, %rax
	jbe	.L30
	addq	$1, -32(%rbp)
	addq	$1, -64(%rbp)
	jmp	.L31
.L30:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	memory(%rip), %rax
	movq	(%rdx,%rax), %rax
	addq	$1, %rax
	cmpq	$2, %rax
	jbe	.L31
	addq	$1, -64(%rbp)
.L31:
	addq	$1, -24(%rbp)
.L26:
	movq	-72(%rbp), %rax
	cmpq	%rax, -24(%rbp)
	jb	.L32
	cmpq	$1, -64(%rbp)
	jbe	.L33
	movq	-32(%rbp), %rax
	movl	$2, %esi
	movl	%eax, %edi
	call	nCr
	movq	-64(%rbp), %rdx
	subq	$2, %rdx
	imulq	%rdx, %rax
	addq	%rax, -16(%rbp)
	movq	-56(%rbp), %rax
	addq	%rax, -16(%rbp)
	movq	-64(%rbp), %rax
	subq	$1, %rax
	imulq	-48(%rbp), %rax
	addq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	subq	$1, %rax
	imulq	-40(%rbp), %rax
	addq	%rax, -16(%rbp)
.L33:
	movq	-16(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L35
	call	__stack_chk_fail@PLT
.L35:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.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:
