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

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x30,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movl   $0x0,-0x28(%rbp)
  movq   $0x0,-0x20(%rbp)
  movq   $0x0,-0x18(%rbp)
  movl   $0x0,-0x10(%rbp)
  lea    D54(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    -0x2c(%rbp),%rax
  mov    %rax,%rsi
  lea    D121(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  lea    D29(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    -0x28(%rbp),%rax
  mov    %rax,%rsi
  lea    D121(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  mov    -0x2c(%rbp),%eax
  cmp    $0xc,%eax
  ja     L144
  mov    %eax,%eax
  lea    0x0(,%rax,4),%rdx
  lea    D4(%rip),%rax
  mov    (%rdx,%rax,1),%eax
  cltq
  lea    D4(%rip),%rdx
  add    %rdx,%rax
  notrack jmp *%rax
  movl   $0x1f,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D155(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  mov    -0x28(%rbp),%eax
  and    $0x3,%eax
  test   %eax,%eax
  jne    L112
  mov    -0x28(%rbp),%edx
  movslq %edx,%rax
  imul   $0x51eb851f,%rax,%rax
  shr    $0x20,%rax
  sar    $0x5,%eax
  mov    %edx,%ecx
  sar    $0x1f,%ecx
  sub    %ecx,%eax
  imul   $0x64,%eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  test   %eax,%eax
  jne    L32
  mov    -0x28(%rbp),%edx
  movslq %edx,%rax
  imul   $0x51eb851f,%rax,%rax
  shr    $0x20,%rax
  sar    $0x7,%eax
  mov    %edx,%ecx
  sar    $0x1f,%ecx
  sub    %ecx,%eax
  imul   $0x190,%eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  test   %eax,%eax
  jne    L112
L32:
  movl   $0x1d,-0x24(%rbp)
  jmp    L87
L112:
  movl   $0x1c,-0x24(%rbp)
L87:
  lea    -0x20(%rbp),%rax
  lea    D207(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1f,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D181(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1e,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D183(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1f,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D156(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1e,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D0(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1f,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D8(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1f,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D113(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1e,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D124(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1f,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D57(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1e,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D19(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  jmp    L144
  movl   $0x1f,-0x24(%rbp)
  lea    -0x20(%rbp),%rax
  lea    D95(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
  nop
L144:
  lea    D117(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  lea    -0x20(%rbp),%rax
  mov    %rax,%rsi
  lea    D145(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    -0x24(%rbp),%eax
  mov    %eax,%esi
  lea    D198(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L54
  call   <__stack_chk_fail@plt>
L54:
  leave
  ret
```

tool_calls: name: extract_symbolic_data
arguments: tag: D54
type_infered: string
name: extract_symbolic_data
arguments: tag: D121
type_infered: string
name: extract_symbolic_data
arguments: tag: D29
type_infered: string
name: extract_symbolic_data
arguments: tag: D155
type_infered: string
name: extract_symbolic_data
arguments: tag: D207
type_infered: string
name: extract_symbolic_data
arguments: tag: D181
type_infered: string
name: extract_symbolic_data
arguments: tag: D183
type_infered: string
name: extract_symbolic_data
arguments: tag: D156
type_infered: string
name: extract_symbolic_data
arguments: tag: D0
type_infered: string
name: extract_symbolic_data
arguments: tag: D8
type_infered: string
name: extract_symbolic_data
arguments: tag: D113
type_infered: string
name: extract_symbolic_data
arguments: tag: D124
type_infered: string
name: extract_symbolic_data
arguments: tag: D57
type_infered: string
name: extract_symbolic_data
arguments: tag: D19
type_infered: string
name: extract_symbolic_data
arguments: tag: D95
type_infered: string
name: extract_symbolic_data
arguments: tag: D117
type_infered: string
name: extract_symbolic_data
arguments: tag: D145
type_infered: string
name: extract_symbolic_data
arguments: tag: D198
type_infered: string

tool: D54: Ingrese el mes:

tool: D121: %d

tool: D29: Ingrese el anio

tool: D155: ENERO

tool: D207: FEBRERO

tool: D181: MARZO

tool: D183: ABRIL

tool: D156: MAYO

tool: D0: JUNIO

tool: D8: JUlIO

tool: D113: AGOSTO

tool: D124: SEPTIEMBRE

tool: D57: OCTUBRE

tool: D19: NOVIEMBRE

tool: D95: DICIEMBRE

tool: D117: .....................

tool: D145: MES : %s


tool: D198: DIAS: %d


assistant: ```c
int main() {
  int m, d, a = 0;
  char cad[20] = "";
  printf("Ingrese el mes:\n");
  scanf("%d", &m);
  printf("Ingrese el anio\n");
  scanf("%d", &a);
  switch (m) {
  case 1:
    d = 31;
    strcpy(cad, "ENERO");
    break;
  case 2:
    if (a % 4 == 0 && (a % 100 != 0 || a % 400 == 0))
      d = 29;
    else
      d = 28;
    strcpy(cad, "FEBRERO");
    break;
  case 3:
    d = 31;
    strcpy(cad, "MARZO");
    break;
  case 4:
    d = 30;
    strcpy(cad, "ABRIL");
    break;
  case 5:
    d = 31;
    strcpy(cad, "MAYO");
    break;
  case 6:
    d = 30;
    strcpy(cad, "JUNIO");
    break;
  case 7:
    d = 31;
    strcpy(cad, "JUlIO");
    break;
  case 8:
    d = 31;
    strcpy(cad, "AGOSTO");
    break;
  case 9:
    d = 30;
    strcpy(cad, "SEPTIEMBRE");
    break;
  case 10:
    d = 31;
    strcpy(cad, "OCTUBRE");
    break;
  case 11:
    d = 30;
    strcpy(cad, "NOVIEMBRE");
    break;
  case 12:
    d = 31;
    strcpy(cad, "DICIEMBRE");
    break;
  }
  printf(".....................\n");
  printf("MES : %s\n", cad);
  printf("DIAS: %d\n", d);
  return 0;
}
```