user: Converte this assembly snippet into its equivalent C code:

```asm
<main>:
  endbr64
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  lea    -0x9000(%rsp),%r11
L8:
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  cmp    %r11,%rsp
  jne    L8
  sub    $0xc60,%rsp
  lea    D11(%rip),%rdi
  lea    D8(%rip),%r14
  mov    %fs:0x28,%rax
  mov    %rax,0x9c58(%rsp)
  xor    %eax,%eax
  lea    0x8(%rsp),%rdx
  lea    0x4(%rsp),%rsi
  lea    0x10(%rsp),%r12
  call   <scanf@plt>
  mov    %r12,%rsi
  mov    %r14,%rdi
  xor    %eax,%eax
  call   <scanf@plt>
  mov    0x4(%rsp),%eax
  cmp    $0x1,%eax
  jle    L90
  lea    0x14(%rsp),%rbx
  mov    $0x1,%ebp
  lea    0xc(%rsp),%r13
  cs nopw 0x0(%rax,%rax,1)
L12:
  mov    %r13,%rsi
  mov    %r14,%rdi
  xor    %eax,%eax
  add    $0x1,%ebp
  call   <scanf@plt>
  mov    0xc(%rsp),%eax
  add    -0x4(%rbx),%eax
  add    $0x4,%rbx
  mov    %eax,-0x4(%rbx)
  mov    0x4(%rsp),%eax
  cmp    %ebp,%eax
  jg     L12
L90:
  mov    0x8(%rsp),%edi
  lea    (%rdi,%rdi,1),%edx
  sub    %edi,%eax
  movslq %edx,%rdx
  mov    %eax,%r8d
  mov    0x10(%rsp,%rdx,4),%esi
  lea    0x1(%rdi),%edx
  cmp    %eax,%edx
  jge    L60
  sub    %edi,%eax
  lea    -0x1(%rax),%r9d
  sub    $0x2,%eax
  cmp    $0x2,%eax
  jbe    L0
  mov    %r9d,%ecx
  movd   %esi,%xmm3
  movslq %edi,%rax
  shr    $0x2,%ecx
  lea    0x4(%r12,%rax,8),%rsi
  pshufd $0x0,%xmm3,%xmm2
  xor    %eax,%eax
  shl    $0x4,%rcx
  nopl   0x0(%rax,%rax,1)
L66:
  movdqu (%rsi,%rax,1),%xmm0
  psubd  (%r12,%rax,1),%xmm0
  add    $0x10,%rax
  movdqa %xmm0,%xmm1
  pcmpgtd %xmm2,%xmm1
  pand   %xmm1,%xmm0
  pandn  %xmm2,%xmm1
  movdqa %xmm1,%xmm2
  por    %xmm0,%xmm2
  cmp    %rcx,%rax
  jne    L66
  movdqa %xmm2,%xmm1
  mov    %r9d,%eax
  psrldq $0x8,%xmm1
  and    $0xfffffffc,%eax
  movdqa %xmm1,%xmm0
  add    %eax,%edx
  pcmpgtd %xmm2,%xmm0
  pand   %xmm0,%xmm1
  pandn  %xmm2,%xmm0
  por    %xmm1,%xmm0
  movdqa %xmm0,%xmm2
  psrldq $0x4,%xmm2
  movdqa %xmm2,%xmm1
  pcmpgtd %xmm0,%xmm1
  pand   %xmm1,%xmm2
  pandn  %xmm0,%xmm1
  por    %xmm2,%xmm1
  movd   %xmm1,%esi
  cmp    %r9d,%eax
  je     L60
L0:
  mov    %edx,%eax
  lea    (%rdi,%rdx,1),%ecx
  sub    %edi,%eax
  movslq %ecx,%rcx
  sub    $0x1,%eax
  mov    0x10(%rsp,%rcx,4),%ecx
  cltq
  sub    0x10(%rsp,%rax,4),%ecx
  cmp    %ecx,%esi
  cmovl  %ecx,%esi
  lea    0x1(%rdx),%ecx
  cmp    %r8d,%ecx
  jge    L60
  lea    (%rdi,%rcx,1),%eax
  sub    %edi,%ecx
  sub    $0x1,%ecx
  cltq
  movslq %ecx,%rcx
  mov    0x10(%rsp,%rax,4),%eax
  sub    0x10(%rsp,%rcx,4),%eax
  cmp    %eax,%esi
  cmovl  %eax,%esi
  add    $0x2,%edx
  cmp    %edx,%r8d
  jle    L60
  lea    (%rdi,%rdx,1),%ecx
  sub    %edi,%edx
  lea    -0x1(%rdx),%eax
  movslq %ecx,%rcx
  cltq
  mov    0x10(%rsp,%rcx,4),%edx
  sub    0x10(%rsp,%rax,4),%edx
  cmp    %edx,%esi
  cmovl  %edx,%esi
L60:
  mov    %r14,%rdi
  call   <printf@plt>
  mov    0x9c58(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L6
  add    $0x9c60,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
L6:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: read_data
arguments: data_label: D11
type_infered: string
name: read_data
arguments: data_label: D8
type_infered: string

tool: D11: %d %d

tool: D8: %d

assistant: ```c
int main() {
  int n, k, box[10000], i, temp, top = 0, sum;
  scanf("%d %d", &n, &k);
  scanf("%d", &box[0]);
  for (i = 1; i < n; i++) {
    scanf("%d", &temp);
    box[i] = box[i - 1] + temp;
  }
  top = box[k + k];
  for (i = k + 1; i < n - k; i++) {
    sum = box[i + k] - box[i - k - 1];
    if (top < sum) {
      top = sum;
    }
  }
  printf("%d", top);
  return 0;
}
```