user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  lea    -0x31000(%rsp),%r11
L39:
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  cmp    %r11,%rsp
  jne    L39
  sub    $0x2e8,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x18(%rbp)
  xor    %eax,%eax
  movl   $0x0,-0x312d8(%rbp)
  lea    -0x312d0(%rbp),%rdx
  mov    $0x0,%eax
  mov    $0x32,%ecx
  mov    %rdx,%rdi
  rep stos %rax,%es:(%rdi)
  jmp    L45
L118:
  lea    -0x312d0(%rbp),%rax
  mov    $0x190,%edx
  mov    $0x0,%esi
  mov    %rax,%rdi
  call   <memset@plt>
  movl   $0xffffffff,-0x312d4(%rbp)
  addl   $0x1,-0x312d8(%rbp)
  mov    $0x0,%eax
  call   <getchar@plt>
  movl   $0x0,-0x312e0(%rbp)
  jmp    L121
L64:
  lea    -0x18aa0(%rbp),%rdx
  mov    -0x312e0(%rbp),%eax
  cltq
  imul   $0x3e8,%rax,%rax
  add    %rdx,%rax
  mov    %rax,%rdi
  call   <gets@plt>
  addl   $0x1,-0x312e0(%rbp)
L121:
  mov    -0x312e8(%rbp),%eax
  cmp    %eax,-0x312e0(%rbp)
  jl     L64
  movl   $0x0,-0x312dc(%rbp)
  jmp    L112
L116:
  lea    -0x31140(%rbp),%rdx
  mov    -0x312dc(%rbp),%eax
  cltq
  imul   $0x3e8,%rax,%rax
  add    %rdx,%rax
  mov    %rax,%rdi
  call   <gets@plt>
  movl   $0x0,-0x312e0(%rbp)
  jmp    L13
L57:
  lea    -0x18aa0(%rbp),%rdx
  mov    -0x312e0(%rbp),%eax
  cltq
  imul   $0x3e8,%rax,%rax
  lea    (%rdx,%rax,1),%rbx
  lea    -0x31140(%rbp),%rdx
  mov    -0x312dc(%rbp),%eax
  cltq
  imul   $0x3e8,%rax,%rax
  add    %rax,%rdx
  lea    -0x400(%rbp),%rax
  mov    %rax,%rsi
  mov    %rdx,%rdi
  call   <strdown@plt>
  mov    %rbx,%rsi
  mov    %eax,%edi
  call   <my_strstr@plt>
  mov    -0x312dc(%rbp),%edx
  movslq %edx,%rdx
  mov    -0x312d0(%rbp,%rdx,4),%edx
  add    %edx,%eax
  mov    %eax,%edx
  mov    -0x312dc(%rbp),%eax
  cltq
  mov    %edx,-0x312d0(%rbp,%rax,4)
  addl   $0x1,-0x312e0(%rbp)
L13:
  mov    -0x312e8(%rbp),%eax
  cmp    %eax,-0x312e0(%rbp)
  jl     L57
  mov    -0x312dc(%rbp),%eax
  cltq
  mov    -0x312d0(%rbp,%rax,4),%eax
  cmp    %eax,-0x312d4(%rbp)
  jge    L28
  mov    -0x312dc(%rbp),%eax
  cltq
  mov    -0x312d0(%rbp,%rax,4),%eax
  mov    %eax,-0x312d4(%rbp)
L28:
  addl   $0x1,-0x312dc(%rbp)
L112:
  mov    -0x312e4(%rbp),%eax
  cmp    %eax,-0x312dc(%rbp)
  jl     L116
  mov    -0x312d8(%rbp),%eax
  mov    %eax,%esi
  lea    D8(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  movl   $0x0,-0x312dc(%rbp)
  jmp    L106
L5:
  mov    -0x312dc(%rbp),%eax
  cltq
  mov    -0x312d0(%rbp,%rax,4),%eax
  cmp    %eax,-0x312d4(%rbp)
  jne    L51
  lea    -0x31140(%rbp),%rdx
  mov    -0x312dc(%rbp),%eax
  cltq
  imul   $0x3e8,%rax,%rax
  add    %rdx,%rax
  mov    %rax,%rdi
  call   <puts@plt>
L51:
  addl   $0x1,-0x312dc(%rbp)
L106:
  mov    -0x312e4(%rbp),%eax
  cmp    %eax,-0x312dc(%rbp)
  jl     L5
  mov    $0xa,%edi
  call   <putchar@plt>
L45:
  lea    -0x312e4(%rbp),%rdx
  lea    -0x312e8(%rbp),%rax
  mov    %rax,%rsi
  lea    D11(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  test   %rax,%rax
  jg     L118
  mov    $0x0,%eax
  mov    -0x18(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L110
  call   <__stack_chk_fail@plt>
L110:
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

tool_calls: name: parse_data
arguments: data_tag: D8
datatype: string
name: parse_data
arguments: data_tag: D11
datatype: string

tool: D8: Excuse Set #%d


tool: D11: %d%d

assistant: ```c
main() {
  char s[100][1000];
  char key[100][1000];
  char temp[1000];
  int i, j, k = 0, l, m, n, max, a[100] = {0};
  while (scanf("%d%d", &m, &n) > 0) {
    memset(a, 0, sizeof(a));
    max = -1;
    k++;
    getchar();
    for (i = 0; i < m; i++)
      gets(key[i]);
    for (j = 0; j < n; j++) {
      gets(s[j]);
      for (i = 0; i < m; i++)
        a[j] += my_strstr(strdown(s[j], temp), key[i]);
      if (a[j] > max)
        max = a[j];
    }
    printf("Excuse Set #%d\n", k);
    for (j = 0; j < n; j++)
      if (a[j] == max)
        puts(s[j]);
    putchar('\n');
  }
  return 0;
}
```