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

```asm
<main>:
  endbr64
  push   %r15
  lea    D77(%rip),%rsi
  lea    D49(%rip),%rdi
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  lea    D12(%rip),%rbp
  push   %rbx
  sub    $0x98,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x88(%rsp)
  xor    %eax,%eax
  lea    0x28(%rsp),%r15
  lea    0x60(%rsp),%r14
  call   <fopen@plt>
  lea    D19(%rip),%rsi
  lea    0x30(%rsp),%r12
  lea    D73(%rip),%rdi
  mov    %rax,%r13
  call   <fopen@plt>
  lea    D15(%rip),%rdi
  mov    %rax,0x18(%rsp)
  call   <printf@plt>
  lea    0x2c(%rsp),%rsi
  lea    D83(%rip),%rdi
  call   <scanf@plt>
  lea    0x24(%rsp),%rax
  movl   $0x0,0x14(%rsp)
  mov    %rax,0x8(%rsp)
L68:
  mov    0x14(%rsp),%eax
  mov    %eax,0x10(%rsp)
  mov    %eax,%edx
  add    $0x1,%eax
  mov    %eax,0x14(%rsp)
  mov    0x2c(%rsp),%eax
  sub    $0x1,%eax
  cmp    %edx,%eax
  je     L87
L18:
  mov    %r12,%rax
  mov    $0x4,%ebx
  mov    %r14,%r12
  mov    %rax,%r14
L38:
  mov    0x8(%rsp),%r8
  mov    %r15,%r9
  mov    %r12,%rcx
  mov    %r14,%rdx
  mov    %rbp,%rsi
  mov    %r13,%rdi
  xor    %eax,%eax
  call   <fscanf@plt>
  mov    0x2c(%rsp),%eax
  sub    $0x1,%eax
  cmp    0x10(%rsp),%eax
  je     L11
L71:
  sub    $0x1,%ebx
  jne    L38
  mov    %r14,%rax
  lea    D1(%rip),%rsi
  mov    %r12,%r14
  mov    %r13,%rdi
  mov    %rax,%rdx
  mov    %rax,%r12
  xor    %eax,%eax
  call   <fscanf@plt>
  mov    0x2c(%rsp),%eax
  sub    $0x1,%eax
  cmp    0x10(%rsp),%eax
  je     L72
L43:
  cmpl   $0x3,0x14(%rsp)
  jne    L68
  mov    %r13,%rdi
  call   <fclose@plt>
  mov    0x18(%rsp),%rdi
  call   <fclose@plt>
  mov    0x88(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L57
  add    $0x98,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L11:
  mov    0x28(%rsp),%r9d
  mov    0x24(%rsp),%r8d
  mov    %r12,%rcx
  mov    %r14,%rdx
  mov    0x18(%rsp),%rdi
  lea    D9(%rip),%rsi
  xor    %eax,%eax
  call   <fprintf@plt>
  jmp    L71
L72:
  mov    0x18(%rsp),%rdi
  mov    %r12,%rdx
  lea    D74(%rip),%rsi
  xor    %eax,%eax
  call   <fprintf@plt>
  jmp    L43
L87:
  mov    0x14(%rsp),%edx
  mov    0x18(%rsp),%rdi
  lea    D4(%rip),%rsi
  xor    %eax,%eax
  call   <fprintf@plt>
  jmp    L18
L57:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: data_label: D77
type_guessed: string
name: disassemble_data
arguments: data_label: D49
type_guessed: string
name: disassemble_data
arguments: data_label: D12
type_guessed: string
name: disassemble_data
arguments: data_label: D19
type_guessed: string
name: disassemble_data
arguments: data_label: D73
type_guessed: string
name: disassemble_data
arguments: data_label: D15
type_guessed: string
name: disassemble_data
arguments: data_label: D83
type_guessed: string
name: disassemble_data
arguments: data_label: D1
type_guessed: string
name: disassemble_data
arguments: data_label: D9
type_guessed: string
name: disassemble_data
arguments: data_label: D74
type_guessed: string
name: disassemble_data
arguments: data_label: D4
type_guessed: string

tool: D77: r

tool: D49: src

tool: D12: %s %s %d %d

tool: D19: w

tool: D73: dest

tool: D15: Che giornata ti interessa: 

tool: D83: %d

tool: D1: %s

tool: D9: %s %s %d-%d


tool: D74: Riposa %s

tool: D4: Giornata %d



assistant: ```c
int main() {
  FILE *src, *dest;
  int i, j, casa, trasferta, g;
  char s1[40], s2[40];
  src = fopen("src", "r");
  dest = fopen("dest", "w");
  printf("Che giornata ti interessa: ");
  scanf("%d", &g);
  for (i = 0; i < 3; i++) {
    if (g - 1 == i)
      fprintf(dest, "Giornata %d\n\n", i + 1);
    for (j = 0; j < 4; j++) {
      fscanf(src, "%s %s %d %d", s1, s2, &casa, &trasferta);
      if (g - 1 == i)
        fprintf(dest, "%s %s %d-%d\n", s1, s2, casa, trasferta);
    }
    fscanf(src, "%s", s1);
    if (g - 1 == i)
      fprintf(dest, "Riposa %s", s1);
  }
  fclose(src);
  fclose(dest);
}
```