user: What would the C source look like for the assembly code provided here?

```asm
<ex5>:
  endbr64
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x20,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x18(%rsp)
  xor    %eax,%eax
  lea    D47(%rip),%rdi
  call   <print@plt>
  lea    D52(%rip),%rdi
  call   <print@plt>
  lea    0xc(%rsp),%rsi
  lea    D93(%rip),%rdi
  call   <scanf@plt>
  cmpl   $0x0,0xc(%rsp)
  jg     L6
  lea    D15(%rip),%r12
  lea    0xc(%rsp),%rbp
  lea    D93(%rip),%rbx
L4:
  mov    %r12,%rdi
  call   <print@plt>
  mov    %rbp,%rsi
  mov    %rbx,%rdi
  call   <scanf@plt>
  cmpl   $0x0,0xc(%rsp)
  jle    L4
L6:
  lea    D26(%rip),%rdi
  call   <print@plt>
  lea    0x10(%rsp),%rsi
  lea    D93(%rip),%rdi
  call   <scanf@plt>
  cmpl   $0x0,0x10(%rsp)
  jg     L25
  lea    D15(%rip),%r12
  lea    0x10(%rsp),%rbp
  lea    D93(%rip),%rbx
L61:
  mov    %r12,%rdi
  call   <print@plt>
  mov    %rbp,%rsi
  mov    %rbx,%rdi
  call   <scanf@plt>
  cmpl   $0x0,0x10(%rsp)
  jle    L61
L25:
  lea    D22(%rip),%rdi
  call   <print@plt>
  lea    0x14(%rsp),%rsi
  lea    D93(%rip),%rdi
  call   <scanf@plt>
  mov    0x14(%rsp),%eax
  test   %eax,%eax
  jg     L63
  lea    D15(%rip),%r12
  lea    0x14(%rsp),%rbp
  lea    D93(%rip),%rbx
L57:
  mov    %r12,%rdi
  call   <print@plt>
  mov    %rbp,%rsi
  mov    %rbx,%rdi
  call   <scanf@plt>
  mov    0x14(%rsp),%eax
  test   %eax,%eax
  jle    L57
L63:
  mov    0xc(%rsp),%edx
  add    0x10(%rsp),%edx
  add    %eax,%edx
  pxor   %xmm1,%xmm1
  cvtsi2sd %edx,%xmm1
  mulsd  D123(%rip),%xmm1
  cvtsd2ss %xmm1,%xmm1
  pxor   %xmm2,%xmm2
  cvtsi2ssl 0xc(%rsp),%xmm2
  movaps %xmm1,%xmm0
  subss  %xmm2,%xmm0
  mulss  %xmm1,%xmm0
  pxor   %xmm3,%xmm3
  cvtsi2ssl 0x10(%rsp),%xmm3
  movaps %xmm1,%xmm2
  subss  %xmm3,%xmm2
  mulss  %xmm2,%xmm0
  pxor   %xmm2,%xmm2
  cvtsi2ss %eax,%xmm2
  subss  %xmm2,%xmm1
  mulss  %xmm1,%xmm0
  call   <sqrt@plt>
  lea    D68(%rip),%rdi
  call   <printf@plt>
  lea    D47(%rip),%rdi
  call   <print@plt>
  mov    0x18(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L56
  add    $0x20,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
L56:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: tag: D47
data_type: string
name: extract_symbolic_data
arguments: tag: D52
data_type: string
name: extract_symbolic_data
arguments: tag: D93
data_type: string
name: extract_symbolic_data
arguments: tag: D15
data_type: string
name: extract_symbolic_data
arguments: tag: D26
data_type: string
name: extract_symbolic_data
arguments: tag: D22
data_type: string
name: extract_symbolic_data
arguments: tag: D123
data_type: byte[8]
name: extract_symbolic_data
arguments: tag: D68
data_type: string

tool: D47: 
------------------------------


tool: D52: Informe a medida do lado a:

tool: D93: %d

tool: D15: Valor invalido, tente novamente:

tool: D26: Informe a medida do lado b:

tool: D22: Informe a medida do lado c:

tool: {"D123": [0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x3f]}

tool: D68: A area do triangulo e: %.2f u.a.


assistant: ```c
void ex5() {
  print("\n------------------------------\n");
  int a, b, c;
  print("Informe a medida do lado a:");
  scanf("%d", &a);
  while (!(a > 0)) {
    print("Valor invalido, tente novamente:");
    scanf("%d", &a);
  }
  print("Informe a medida do lado b:");
  scanf("%d", &b);
  while (!(b > 0)) {
    print("Valor invalido, tente novamente:");
    scanf("%d", &b);
  }
  print("Informe a medida do lado c:");
  scanf("%d", &c);
  while (!(c > 0)) {
    print("Valor invalido, tente novamente:");
    scanf("%d", &c);
  }
  float s = (a + b + c) / 2.;
  float area = sqrt(s * (s - a) * (s - b) * (s - c));
  printf("A area do triangulo e: %.2f u.a.\n", area);
  print("\n------------------------------\n");
}
```