user: Translate the below assembly code into C programming language:

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0x38,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x18(%rbp)
  xor    %eax,%eax
  movl   $0x0,-0x34(%rbp)
  movl   $0x0,-0x30(%rbp)
  movl   $0x0,-0x2c(%rbp)
  lea    D42(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x1,%edi
  call   <malloc@plt>
  mov    %rax,-0x28(%rbp)
  mov    $0x1,%edi
  call   <malloc@plt>
  mov    %rax,-0x20(%rbp)
  jmp    L60
L63:
  movzbl -0x35(%rbp),%eax
  cmp    $0x20,%al
  je     L28
  movzbl -0x35(%rbp),%eax
  cmp    $0xa,%al
  jne    L19
L28:
  mov    -0x20(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  mov    %eax,%ebx
  mov    -0x28(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  cmp    %eax,%ebx
  jle    L25
  mov    -0x20(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  mov    %eax,%edx
  mov    -0x28(%rbp),%rax
  mov    %edx,%esi
  mov    %rax,%rdi
  call   <realloc@plt>
  mov    %rax,-0x28(%rbp)
  mov    -0x20(%rbp),%rdx
  mov    -0x28(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
L25:
  addl   $0x1,-0x34(%rbp)
  movl   $0x0,-0x2c(%rbp)
  movzbl -0x35(%rbp),%eax
  cmp    $0xa,%al
  je     L56
  jmp    L60
L19:
  mov    -0x2c(%rbp),%eax
  lea    0x1(%rax),%edx
  mov    -0x20(%rbp),%rax
  mov    %edx,%esi
  mov    %rax,%rdi
  call   <realloc@plt>
  mov    %rax,-0x20(%rbp)
  mov    -0x2c(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x20(%rbp),%rax
  add    %rax,%rdx
  movzbl -0x35(%rbp),%eax
  mov    %al,(%rdx)
  addl   $0x1,-0x30(%rbp)
  addl   $0x1,-0x2c(%rbp)
L60:
  lea    -0x35(%rbp),%rax
  mov    %rax,%rsi
  lea    D21(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  cmp    $0x1,%eax
  je     L63
  jmp    L5
L56:
  nop
L5:
  mov    -0x34(%rbp),%eax
  mov    %eax,%esi
  lea    D23(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    -0x28(%rbp),%rax
  mov    %rax,%rsi
  lea    D6(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  pxor   %xmm0,%xmm0
  cvtsi2ssl -0x30(%rbp),%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ssl -0x34(%rbp),%xmm1
  divss  %xmm1,%xmm0
  pxor   %xmm2,%xmm2
  cvtss2sd %xmm0,%xmm2
  movq   %xmm2,%rax
  movq   %rax,%xmm0
  lea    D14(%rip),%rax
  mov    %rax,%rdi
  mov    $0x1,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  mov    -0x18(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L74
  call   <__stack_chk_fail@plt>
L74:
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

tool_calls: name: unpack_data
arguments: label: D42
type: string
name: unpack_data
arguments: label: D21
type: string
name: unpack_data
arguments: label: D23
type: string
name: unpack_data
arguments: label: D6
type: string
name: unpack_data
arguments: label: D14
type: string

tool: D42: Frase? 

tool: D21: %c

tool: D23: Numero de palavras: %d


tool: D6: Palavra maior: %s


tool: D14: Comprimento medio: %.1f


assistant: ```c
int main() {
  char c, *max, *p;
  int n = 0, l = 0, i = 0;
  printf("Frase? ");
  max = (char *)malloc(sizeof(char));
  p = (char *)malloc(sizeof(char));
  while (scanf("%c", &c) == 1) {
    if (c == ' ' || c == '\n') {
      if (strlen(p) > strlen(max)) {
        max = (char *)realloc(max, sizeof(char) * strlen(p));
        strcpy(max, p);
      }
      n++;
      i = 0;
      if (c == '\n')
        break;
    } else {
      p = (char *)realloc(p, sizeof(char) * (i + 1));
      p[i] = c;
      l++;
      i++;
    }
  }
  printf("Numero de palavras: %d\n", n);
  printf("Palavra maior: %s\n", max);
  printf("Comprimento medio: %.1f\n", (float)l / (float)n);
  return 0;
}
```