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(){
  char S[101],T[101];
  int S_length=0,T_length=0,ans=0;
  scanf("%s",S);
  for (int i = 0; i < 101; i++){
    if(S[i]!='\000'){
      S_length++;
    }else{
      break;
    }
  }
  scanf("%s",T);
  for (int i = 0; i < 101; i++){
    if(T[i]!='\000'){ 
      T_length++;
    }else{
      break;
    }
  }

  for (int i = 0; i < S_length-1; i++){
    int min=S[i];
    int t,s=i;
    for (int j = i+1; j < S_length; j++){
      if (min>S[j]){
        min=S[j];
        s=j;
      }
    }
    t=S[i]; S[i]=S[s]; S[s]=t;
  }
  
  for (int i = 0; i < T_length-1; i++){
    int max=S[i];
    int t,l=i;
    for (int j = i+1; j < T_length; j++){
      if (max<T[j]){
        max=T[j];
        l=j;
      }
    }
    t=T[i]; T[i]=T[l]; T[l]=t;
  }

  for (int i = 0; i < S_length; i++)
  {
    if(S[i]==T[i]){
      ans=0;
    }else if(S[i]<T[i]){
      ans=1;
      break;
    }else{
      ans=-1;
      break;
    }
  }

  if (ans==1){
    puts("Yes");
  }else if (ans==0&&S_length<T_length){
    puts("Yes");
  }else{
    puts("No");
  }

  return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%s"
.LC1:
	.string	"Yes"
.LC2:
	.string	"No"
	.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	$288, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -288(%rbp)
	movl	$0, -284(%rbp)
	movl	$0, -280(%rbp)
	leaq	-224(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -276(%rbp)
	jmp	.L2
.L6:
	movl	-276(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	testb	%al, %al
	je	.L34
	addl	$1, -288(%rbp)
	addl	$1, -276(%rbp)
.L2:
	cmpl	$100, -276(%rbp)
	jle	.L6
	jmp	.L5
.L34:
	nop
.L5:
	leaq	-112(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -272(%rbp)
	jmp	.L7
.L11:
	movl	-272(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	testb	%al, %al
	je	.L35
	addl	$1, -284(%rbp)
	addl	$1, -272(%rbp)
.L7:
	cmpl	$100, -272(%rbp)
	jle	.L11
	jmp	.L10
.L35:
	nop
.L10:
	movl	$0, -268(%rbp)
	jmp	.L12
.L16:
	movl	-268(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -264(%rbp)
	movl	-268(%rbp), %eax
	movl	%eax, -260(%rbp)
	movl	-268(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -256(%rbp)
	jmp	.L13
.L15:
	movl	-256(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	cmpl	%eax, -264(%rbp)
	jle	.L14
	movl	-256(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -264(%rbp)
	movl	-256(%rbp), %eax
	movl	%eax, -260(%rbp)
.L14:
	addl	$1, -256(%rbp)
.L13:
	movl	-256(%rbp), %eax
	cmpl	-288(%rbp), %eax
	jl	.L15
	movl	-268(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -228(%rbp)
	movl	-260(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-268(%rbp), %eax
	cltq
	movb	%dl, -224(%rbp,%rax)
	movl	-228(%rbp), %eax
	movl	%eax, %edx
	movl	-260(%rbp), %eax
	cltq
	movb	%dl, -224(%rbp,%rax)
	addl	$1, -268(%rbp)
.L12:
	movl	-288(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -268(%rbp)
	jl	.L16
	movl	$0, -252(%rbp)
	jmp	.L17
.L21:
	movl	-252(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -248(%rbp)
	movl	-252(%rbp), %eax
	movl	%eax, -244(%rbp)
	movl	-252(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -240(%rbp)
	jmp	.L18
.L20:
	movl	-240(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	cmpl	%eax, -248(%rbp)
	jge	.L19
	movl	-240(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -248(%rbp)
	movl	-240(%rbp), %eax
	movl	%eax, -244(%rbp)
.L19:
	addl	$1, -240(%rbp)
.L18:
	movl	-240(%rbp), %eax
	cmpl	-284(%rbp), %eax
	jl	.L20
	movl	-252(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -232(%rbp)
	movl	-244(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %edx
	movl	-252(%rbp), %eax
	cltq
	movb	%dl, -112(%rbp,%rax)
	movl	-232(%rbp), %eax
	movl	%eax, %edx
	movl	-244(%rbp), %eax
	cltq
	movb	%dl, -112(%rbp,%rax)
	addl	$1, -252(%rbp)
.L17:
	movl	-284(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -252(%rbp)
	jl	.L21
	movl	$0, -236(%rbp)
	jmp	.L22
.L27:
	movl	-236(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-236(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	cmpb	%al, %dl
	jne	.L23
	movl	$0, -280(%rbp)
	jmp	.L33
.L23:
	movl	-236(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-236(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	cmpb	%al, %dl
	jge	.L25
	movl	$1, -280(%rbp)
	jmp	.L26
.L25:
	movl	$-1, -280(%rbp)
	jmp	.L26
.L33:
	addl	$1, -236(%rbp)
.L22:
	movl	-236(%rbp), %eax
	cmpl	-288(%rbp), %eax
	jl	.L27
.L26:
	cmpl	$1, -280(%rbp)
	jne	.L28
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	jmp	.L29
.L28:
	cmpl	$0, -280(%rbp)
	jne	.L30
	movl	-288(%rbp), %eax
	cmpl	-284(%rbp), %eax
	jge	.L30
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	jmp	.L29
.L30:
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L29:
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L32
	call	__stack_chk_fail@PLT
.L32:
	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	"%s"
.LC1:
	.string	"Yes"
.LC2:
	.string	"No"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	leaq	.LC0(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	movq	%r13, %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$232, %rsp
	.cfi_def_cfa_offset 272
	movq	%fs:40, %rax
	movq	%rax, 216(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %rbx
	movq	%rbx, %rsi
	call	__isoc99_scanf@PLT
	xorl	%eax, %eax
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L46:
	addq	$1, %rax
	cmpq	$101, %rax
	je	.L45
.L3:
	cmpb	$0, (%rbx,%rax)
	movl	%eax, %ebp
	jne	.L46
.L2:
	leaq	112(%rsp), %r12
	movq	%r13, %rdi
	xorl	%eax, %eax
	movq	%r12, %rsi
	call	__isoc99_scanf@PLT
	xorl	%eax, %eax
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L48:
	addq	$1, %rax
	cmpq	$101, %rax
	je	.L47
.L5:
	cmpb	$0, (%r12,%rax)
	movl	%eax, %esi
	jne	.L48
	leal	-1(%rbp), %r11d
	testl	%r11d, %r11d
	jle	.L11
.L12:
	movl	$1, %r13d
	movq	%rbx, %r9
	xorl	%r8d, %r8d
	subq	%rbx, %r13
	.p2align 4,,10
	.p2align 3
.L10:
	movsbl	(%r9), %ecx
	movslq	%r8d, %rdi
	addl	$1, %r8d
	movl	%ecx, %r10d
	cmpl	%r8d, %ebp
	jle	.L26
	leaq	0(%r13,%r9), %rax
	.p2align 4,,10
	.p2align 3
.L9:
	movsbl	(%rbx,%rax), %edx
	cmpl	%edx, %ecx
	jle	.L8
	movslq	%eax, %rdi
	movl	%edx, %ecx
.L8:
	addq	$1, %rax
	cmpl	%eax, %ebp
	jg	.L9
	movzbl	(%rsp,%rdi), %eax
.L7:
	movb	%al, (%r9)
	addq	$1, %r9
	movb	%r10b, (%rsp,%rdi)
	cmpl	%r8d, %r11d
	jg	.L10
.L11:
	leal	-1(%rsi), %r10d
	testl	%r10d, %r10d
	jle	.L13
.L24:
	movl	$1, %r8d
	xorl	%r9d, %r9d
	leaq	-1(%rsp), %r13
	leaq	111(%rsp), %r11
	.p2align 4,,10
	.p2align 3
.L17:
	movslq	%r9d, %rdi
	movsbl	0(%r13,%r8), %ecx
	addl	$1, %r9d
	cmpl	%r8d, %esi
	jle	.L14
	movq	%r8, %rax
	.p2align 4,,10
	.p2align 3
.L16:
	movsbl	(%r12,%rax), %edx
	cmpl	%edx, %ecx
	jge	.L15
	movslq	%eax, %rdi
	movl	%edx, %ecx
.L15:
	addq	$1, %rax
	cmpl	%eax, %esi
	jg	.L16
.L14:
	leaq	(%r11,%r8), %rax
	movzbl	112(%rsp,%rdi), %ecx
	addq	$1, %r8
	movzbl	(%rax), %edx
	movb	%cl, (%rax)
	movb	%dl, 112(%rsp,%rdi)
	cmpl	%r10d, %r9d
	jl	.L17
.L13:
	testl	%ebp, %ebp
	je	.L18
	movslq	%ebp, %rdx
	xorl	%eax, %eax
	jmp	.L20
	.p2align 4,,10
	.p2align 3
.L49:
	addq	$1, %rax
	cmpq	%rax, %rdx
	je	.L18
.L20:
	movzbl	(%r12,%rax), %edi
	cmpb	%dil, (%rbx,%rax)
	je	.L49
	jge	.L50
.L23:
	leaq	.LC1(%rip), %rdi
	call	puts@PLT
.L22:
	movq	216(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L51
	addq	$232, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L26:
	.cfi_restore_state
	movl	%ecx, %eax
	jmp	.L7
.L18:
	cmpl	%esi, %ebp
	jl	.L23
.L50:
	leaq	.LC2(%rip), %rdi
	call	puts@PLT
	jmp	.L22
.L47:
	leal	-1(%rbp), %r11d
	movl	$101, %esi
	movl	$100, %r10d
	testl	%r11d, %r11d
	jg	.L12
	jmp	.L24
.L45:
	movl	$101, %ebp
	jmp	.L2
.L51:
	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	"%s"
.LC1:
	.string	"Yes"
.LC2:
	.string	"No"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	leaq	.LC0(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	movq	%r13, %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$232, %rsp
	.cfi_def_cfa_offset 272
	movq	%fs:40, %rax
	movq	%rax, 216(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %rbx
	movq	%rbx, %rsi
	call	__isoc99_scanf@PLT
	xorl	%eax, %eax
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L46:
	addq	$1, %rax
	cmpq	$101, %rax
	je	.L45
.L3:
	cmpb	$0, (%rbx,%rax)
	movl	%eax, %ebp
	jne	.L46
.L2:
	leaq	112(%rsp), %r12
	movq	%r13, %rdi
	xorl	%eax, %eax
	movq	%r12, %rsi
	call	__isoc99_scanf@PLT
	xorl	%eax, %eax
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L48:
	addq	$1, %rax
	cmpq	$101, %rax
	je	.L47
.L5:
	cmpb	$0, (%r12,%rax)
	movl	%eax, %esi
	jne	.L48
	leal	-1(%rbp), %r11d
	testl	%r11d, %r11d
	jle	.L11
.L12:
	movl	$1, %r13d
	movq	%rbx, %r9
	xorl	%r8d, %r8d
	subq	%rbx, %r13
	.p2align 4,,10
	.p2align 3
.L10:
	movsbl	(%r9), %ecx
	movslq	%r8d, %rdi
	addl	$1, %r8d
	movl	%ecx, %r10d
	cmpl	%r8d, %ebp
	jle	.L26
	leaq	0(%r13,%r9), %rax
	.p2align 4,,10
	.p2align 3
.L9:
	movsbl	(%rbx,%rax), %edx
	cmpl	%edx, %ecx
	jle	.L8
	movslq	%eax, %rdi
	movl	%edx, %ecx
.L8:
	addq	$1, %rax
	cmpl	%eax, %ebp
	jg	.L9
	movzbl	(%rsp,%rdi), %eax
.L7:
	movb	%al, (%r9)
	addq	$1, %r9
	movb	%r10b, (%rsp,%rdi)
	cmpl	%r8d, %r11d
	jg	.L10
.L11:
	leal	-1(%rsi), %r10d
	testl	%r10d, %r10d
	jle	.L13
.L24:
	movl	$1, %r8d
	xorl	%r9d, %r9d
	leaq	-1(%rsp), %r13
	leaq	111(%rsp), %r11
	.p2align 4,,10
	.p2align 3
.L17:
	movslq	%r9d, %rdi
	movsbl	0(%r13,%r8), %ecx
	addl	$1, %r9d
	cmpl	%r8d, %esi
	jle	.L14
	movq	%r8, %rax
	.p2align 4,,10
	.p2align 3
.L16:
	movsbl	(%r12,%rax), %edx
	cmpl	%edx, %ecx
	jge	.L15
	movslq	%eax, %rdi
	movl	%edx, %ecx
.L15:
	addq	$1, %rax
	cmpl	%eax, %esi
	jg	.L16
.L14:
	leaq	(%r11,%r8), %rax
	movzbl	112(%rsp,%rdi), %ecx
	addq	$1, %r8
	movzbl	(%rax), %edx
	movb	%cl, (%rax)
	movb	%dl, 112(%rsp,%rdi)
	cmpl	%r10d, %r9d
	jl	.L17
.L13:
	testl	%ebp, %ebp
	je	.L18
	movslq	%ebp, %rdx
	xorl	%eax, %eax
	jmp	.L20
	.p2align 4,,10
	.p2align 3
.L49:
	addq	$1, %rax
	cmpq	%rax, %rdx
	je	.L18
.L20:
	movzbl	(%r12,%rax), %edi
	cmpb	%dil, (%rbx,%rax)
	je	.L49
	jge	.L50
.L23:
	leaq	.LC1(%rip), %rdi
	call	puts@PLT
.L22:
	movq	216(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L51
	addq	$232, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L26:
	.cfi_restore_state
	movl	%ecx, %eax
	jmp	.L7
.L18:
	cmpl	%esi, %ebp
	jl	.L23
.L50:
	leaq	.LC2(%rip), %rdi
	call	puts@PLT
	jmp	.L22
.L47:
	leal	-1(%rbp), %r11d
	movl	$101, %esi
	movl	$100, %r10d
	testl	%r11d, %r11d
	jg	.L12
	jmp	.L24
.L45:
	movl	$101, %ebp
	jmp	.L2
.L51:
	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(){
  char S[101],T[101];
  int S_length=0,T_length=0,ans=0;
  scanf("%s",S);
  for (int i = 0; i < 101; i++){
    if(S[i]!='\000'){
      S_length++;
    }else{
      break;
    }
  }
  scanf("%s",T);
  for (int i = 0; i < 101; i++){
    if(T[i]!='\000'){ 
      T_length++;
    }else{
      break;
    }
  }

  for (int i = 0; i < S_length-1; i++){
    int min=S[i];
    int t,s=i;
    for (int j = i+1; j < S_length; j++){
      if (min>S[j]){
        min=S[j];
        s=j;
      }
    }
    t=S[i]; S[i]=S[s]; S[s]=t;
  }
  
  for (int i = 0; i < T_length-1; i++){
    int max=S[i];
    int t,l=i;
    for (int j = i+1; j < T_length; j++){
      if (max<T[j]){
        max=T[j];
        l=j;
      }
    }
    t=T[i]; T[i]=T[l]; T[l]=t;
  }

  for (int i = 0; i < S_length; i++)
  {
    if(S[i]==T[i]){
      ans=0;
    }else if(S[i]<T[i]){
      ans=1;
      break;
    }else{
      ans=-1;
      break;
    }
  }

  if (ans==1){
    puts("Yes");
  }else if (ans==0&&S_length<T_length){
    puts("Yes");
  }else{
    puts("No");
  }

  return 0;
}
ratcode
salta
 x
ww
 zzz
{zz
 cd
bac
 xx
axy
 ratcode
salt`
 zzz
{yz
 y
ww
 dc
bac
 xx
yxa

Yes
 No
 Yes
 No
 Yes
 Yes
 Yes
 No
 No
 Yes

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(){
  char S[101],T[101];
  int S_length=0,T_length=0,ans=0;
  scanf("%s",S);
  for (int i = 0; i < 101; i++){
    if(S[i]!='\000'){
      S_length++;
    }else{
      break;
    }
  }
  scanf("%s",T);
  for (int i = 0; i < 101; i++){
    if(T[i]!='\000'){ 
      T_length++;
    }else{
      break;
    }
  }

  for (int i = 0; i < S_length-1; i++){
    int min=S[i];
    int t,s=i;
    for (int j = i+1; j < S_length; j++){
      if (min>S[j]){
        min=S[j];
        s=j;
      }
    }
    t=S[i]; S[i]=S[s]; S[s]=t;
  }
  
  for (int i = 0; i < T_length-1; i++){
    int max=S[i];
    int t,l=i;
    for (int j = i+1; j < T_length; j++){
      if (max<T[j]){
        max=T[j];
        l=j;
      }
    }
    t=T[i]; T[i]=T[l]; T[l]=t;
  }

  for (int i = 0; i < S_length; i++)
  {
    if(S[i]==T[i]){
      ans=0;
    }else if(S[i]<T[i]){
      ans=1;
      break;
    }else{
      ans=-1;
      break;
    }
  }

  if (ans==1){
    puts("Yes");
  }else if (ans==0&&S_length<T_length){
    puts("Yes");
  }else{
    puts("No");
  }

  return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata
.LC0:
	.string	"%s"
.LC1:
	.string	"Yes"
.LC2:
	.string	"No"
	.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	$288, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -288(%rbp)
	movl	$0, -284(%rbp)
	movl	$0, -280(%rbp)
	leaq	-224(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -276(%rbp)
	jmp	.L2
.L6:
	movl	-276(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	testb	%al, %al
	je	.L34
	addl	$1, -288(%rbp)
	addl	$1, -276(%rbp)
.L2:
	cmpl	$100, -276(%rbp)
	jle	.L6
	jmp	.L5
.L34:
	nop
.L5:
	leaq	-112(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -272(%rbp)
	jmp	.L7
.L11:
	movl	-272(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	testb	%al, %al
	je	.L35
	addl	$1, -284(%rbp)
	addl	$1, -272(%rbp)
.L7:
	cmpl	$100, -272(%rbp)
	jle	.L11
	jmp	.L10
.L35:
	nop
.L10:
	movl	$0, -268(%rbp)
	jmp	.L12
.L16:
	movl	-268(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -264(%rbp)
	movl	-268(%rbp), %eax
	movl	%eax, -260(%rbp)
	movl	-268(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -256(%rbp)
	jmp	.L13
.L15:
	movl	-256(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	cmpl	%eax, -264(%rbp)
	jle	.L14
	movl	-256(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -264(%rbp)
	movl	-256(%rbp), %eax
	movl	%eax, -260(%rbp)
.L14:
	addl	$1, -256(%rbp)
.L13:
	movl	-256(%rbp), %eax
	cmpl	-288(%rbp), %eax
	jl	.L15
	movl	-268(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -228(%rbp)
	movl	-260(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-268(%rbp), %eax
	cltq
	movb	%dl, -224(%rbp,%rax)
	movl	-228(%rbp), %eax
	movl	%eax, %edx
	movl	-260(%rbp), %eax
	cltq
	movb	%dl, -224(%rbp,%rax)
	addl	$1, -268(%rbp)
.L12:
	movl	-288(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -268(%rbp)
	jl	.L16
	movl	$0, -252(%rbp)
	jmp	.L17
.L21:
	movl	-252(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -248(%rbp)
	movl	-252(%rbp), %eax
	movl	%eax, -244(%rbp)
	movl	-252(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -240(%rbp)
	jmp	.L18
.L20:
	movl	-240(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	cmpl	%eax, -248(%rbp)
	jge	.L19
	movl	-240(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -248(%rbp)
	movl	-240(%rbp), %eax
	movl	%eax, -244(%rbp)
.L19:
	addl	$1, -240(%rbp)
.L18:
	movl	-240(%rbp), %eax
	cmpl	-284(%rbp), %eax
	jl	.L20
	movl	-252(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -232(%rbp)
	movl	-244(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %edx
	movl	-252(%rbp), %eax
	cltq
	movb	%dl, -112(%rbp,%rax)
	movl	-232(%rbp), %eax
	movl	%eax, %edx
	movl	-244(%rbp), %eax
	cltq
	movb	%dl, -112(%rbp,%rax)
	addl	$1, -252(%rbp)
.L17:
	movl	-284(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -252(%rbp)
	jl	.L21
	movl	$0, -236(%rbp)
	jmp	.L22
.L27:
	movl	-236(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-236(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	cmpb	%al, %dl
	jne	.L23
	movl	$0, -280(%rbp)
	jmp	.L33
.L23:
	movl	-236(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-236(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	cmpb	%al, %dl
	jge	.L25
	movl	$1, -280(%rbp)
	jmp	.L26
.L25:
	movl	$-1, -280(%rbp)
	jmp	.L26
.L33:
	addl	$1, -236(%rbp)
.L22:
	movl	-236(%rbp), %eax
	cmpl	-288(%rbp), %eax
	jl	.L27
.L26:
	cmpl	$1, -280(%rbp)
	jne	.L28
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	jmp	.L29
.L28:
	cmpl	$0, -280(%rbp)
	jne	.L30
	movl	-288(%rbp), %eax
	cmpl	-284(%rbp), %eax
	jge	.L30
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	jmp	.L29
.L30:
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L29:
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L32
	call	__stack_chk_fail@PLT
.L32:
	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	"%s"
.LC1:
	.string	"Yes"
.LC2:
	.string	"No"
	.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	$288, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -288(%rbp)
	movl	$0, -284(%rbp)
	movl	$0, -280(%rbp)
	leaq	-224(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -276(%rbp)
	jmp	.L2
.L6:
	movl	-276(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	testb	%al, %al
	je	.L34
	addl	$1, -288(%rbp)
	addl	$1, -276(%rbp)
.L2:
	cmpl	$100, -276(%rbp)
	jle	.L6
	jmp	.L5
.L34:
	nop
.L5:
	leaq	-112(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -272(%rbp)
	jmp	.L7
.L11:
	movl	-272(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	testb	%al, %al
	je	.L35
	addl	$1, -284(%rbp)
	addl	$1, -272(%rbp)
.L7:
	cmpl	$100, -272(%rbp)
	jle	.L11
	jmp	.L10
.L35:
	nop
.L10:
	movl	$0, -268(%rbp)
	jmp	.L12
.L16:
	movl	-268(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -264(%rbp)
	movl	-268(%rbp), %eax
	movl	%eax, -260(%rbp)
	movl	-268(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -256(%rbp)
	jmp	.L13
.L15:
	movl	-256(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	cmpl	%eax, -264(%rbp)
	jle	.L14
	movl	-256(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -264(%rbp)
	movl	-256(%rbp), %eax
	movl	%eax, -260(%rbp)
.L14:
	addl	$1, -256(%rbp)
.L13:
	movl	-256(%rbp), %eax
	cmpl	-288(%rbp), %eax
	jl	.L15
	movl	-268(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -228(%rbp)
	movl	-260(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-268(%rbp), %eax
	cltq
	movb	%dl, -224(%rbp,%rax)
	movl	-228(%rbp), %eax
	movl	%eax, %edx
	movl	-260(%rbp), %eax
	cltq
	movb	%dl, -224(%rbp,%rax)
	addl	$1, -268(%rbp)
.L12:
	movl	-288(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -268(%rbp)
	jl	.L16
	movl	$0, -252(%rbp)
	jmp	.L17
.L21:
	movl	-252(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -248(%rbp)
	movl	-252(%rbp), %eax
	movl	%eax, -244(%rbp)
	movl	-252(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -240(%rbp)
	jmp	.L18
.L20:
	movl	-240(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	cmpl	%eax, -248(%rbp)
	jge	.L19
	movl	-240(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -248(%rbp)
	movl	-240(%rbp), %eax
	movl	%eax, -244(%rbp)
.L19:
	addl	$1, -240(%rbp)
.L18:
	movl	-240(%rbp), %eax
	cmpl	-284(%rbp), %eax
	jl	.L20
	movl	-252(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	movsbl	%al, %eax
	movl	%eax, -232(%rbp)
	movl	-244(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %edx
	movl	-252(%rbp), %eax
	cltq
	movb	%dl, -112(%rbp,%rax)
	movl	-232(%rbp), %eax
	movl	%eax, %edx
	movl	-244(%rbp), %eax
	cltq
	movb	%dl, -112(%rbp,%rax)
	addl	$1, -252(%rbp)
.L17:
	movl	-284(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -252(%rbp)
	jl	.L21
	movl	$0, -236(%rbp)
	jmp	.L22
.L27:
	movl	-236(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-236(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	cmpb	%al, %dl
	jne	.L23
	movl	$0, -280(%rbp)
	jmp	.L33
.L23:
	movl	-236(%rbp), %eax
	cltq
	movzbl	-224(%rbp,%rax), %edx
	movl	-236(%rbp), %eax
	cltq
	movzbl	-112(%rbp,%rax), %eax
	cmpb	%al, %dl
	jge	.L25
	movl	$1, -280(%rbp)
	jmp	.L26
.L25:
	movl	$-1, -280(%rbp)
	jmp	.L26
.L33:
	addl	$1, -236(%rbp)
.L22:
	movl	-236(%rbp), %eax
	cmpl	-288(%rbp), %eax
	jl	.L27
.L26:
	cmpl	$1, -280(%rbp)
	jne	.L28
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	jmp	.L29
.L28:
	cmpl	$0, -280(%rbp)
	jne	.L30
	movl	-288(%rbp), %eax
	cmpl	-284(%rbp), %eax
	jge	.L30
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	jmp	.L29
.L30:
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L29:
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L32
	call	__stack_chk_fail@PLT
.L32:
	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:
