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

```asm
<main>:
  endbr64
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x30,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x28(%rsp)
  xor    %eax,%eax
  lea    0x8(%rsp),%rsi
  lea    D11(%rip),%rdi
  call   <scanf@plt>
  cmpl   $0x0,0x8(%rsp)
  jle    L50
  mov    $0x1,%ebx
  lea    D23(%rip),%rbp
  lea    D45(%rip),%r13
  lea    D51(%rip),%r12
  lea    D33(%rip),%r14
  jmp    L68
L88:
  mov    %ebx,%esi
  lea    D9(%rip),%rdi
  call   <printf@plt>
L24:
  add    $0x1,%ebx
  cmp    %ebx,0x8(%rsp)
  jl     L50
L68:
  lea    0x14(%rsp),%rcx
  lea    0x10(%rsp),%rdx
  lea    0xc(%rsp),%rsi
  lea    0x24(%rsp),%rax
  push   %rax
  lea    0x28(%rsp),%rax
  push   %rax
  lea    0x2c(%rsp),%r9
  lea    0x28(%rsp),%r8
  mov    %rbp,%rdi
  mov    $0x0,%eax
  call   <scanf@plt>
  mov    0x2c(%rsp),%edx
  mov    0x30(%rsp),%eax
  add    $0x10,%rsp
  cmp    %eax,%edx
  jle    L81
  mov    %edx,0x20(%rsp)
  mov    %eax,0x1c(%rsp)
L81:
  mov    0x1c(%rsp),%edx
  mov    0x24(%rsp),%eax
  cmp    %eax,%edx
  jle    L134
  mov    %edx,0x24(%rsp)
  mov    %eax,0x1c(%rsp)
L134:
  mov    0x20(%rsp),%edx
  mov    0x24(%rsp),%eax
  cmp    %eax,%edx
  jle    L18
  mov    %edx,0x24(%rsp)
  mov    %eax,0x20(%rsp)
L18:
  mov    0x10(%rsp),%eax
  add    0xc(%rsp),%eax
  add    0x14(%rsp),%eax
  add    0x18(%rsp),%eax
  mov    0x20(%rsp),%ecx
  add    0x24(%rsp),%ecx
  mov    %ecx,%edx
  shr    $0x1f,%edx
  add    %ecx,%edx
  sar    %edx
  add    %edx,%eax
  cmp    $0x59,%eax
  jg     L88
  lea    -0x50(%rax),%edx
  cmp    $0x9,%edx
  jbe    L145
  lea    -0x46(%rax),%edx
  cmp    $0x9,%edx
  jbe    L107
  sub    $0x3c,%eax
  cmp    $0x9,%eax
  ja     L140
  mov    %ebx,%esi
  mov    %r12,%rdi
  call   <printf@plt>
  jmp    L24
L145:
  mov    %ebx,%esi
  lea    D8(%rip),%rdi
  call   <printf@plt>
  jmp    L24
L107:
  mov    %ebx,%esi
  mov    %r14,%rdi
  call   <printf@plt>
  jmp    L24
L140:
  mov    %ebx,%esi
  mov    %r13,%rdi
  call   <printf@plt>
  jmp    L24
L50:
  mov    0x28(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L131
  mov    $0x0,%eax
  add    $0x30,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  ret
L131:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: label: D11
data_type: string
name: disassemble_data
arguments: label: D23
data_type: string
name: disassemble_data
arguments: label: D45
data_type: string
name: disassemble_data
arguments: label: D51
data_type: string
name: disassemble_data
arguments: label: D33
data_type: string
name: disassemble_data
arguments: label: D9
data_type: string
name: disassemble_data
arguments: label: D8
data_type: string

tool: D11: %d

tool: D23: %d%d%d%d%d%d%d

tool: D45: Case %d: F


tool: D51: Case %d: D


tool: D33: Case %d: C


tool: D9: Case %d: A


tool: D8: Case %d: B


assistant: ```c
int main() {
  int t, i;
  scanf("%d", &t);
  for (i = 1; i <= t; i++) {
    int t1, t2, f, a, ct1, ct2, ct3, c, T, temp;
    scanf("%d%d%d%d%d%d%d", &t1, &t2, &f, &a, &ct1, &ct2, &ct3);
    if (ct1 > ct2) {
      temp = ct2;
      ct2 = ct1;
      ct1 = temp;
    }
    if (ct1 > ct3) {
      temp = ct3;
      ct3 = ct1;
      ct1 = temp;
    }
    if (ct2 > ct3) {
      temp = ct3;
      ct3 = ct2;
      ct2 = temp;
    }
    c = (ct3 + ct2) / 2;
    T = t1 + t2 + f + a + c;
    if (T >= 90)
      printf("Case %d: A\n", i);
    else if (T >= 80 && T < 90)
      printf("Case %d: B\n", i);
    else if (T >= 70 && T < 80)
      printf("Case %d: C\n", i);
    else if (T >= 60 && T < 70)
      printf("Case %d: D\n", i);
    else
      printf("Case %d: F\n", i);
  }
  return 0;
}
```