user: Please show me the C implementation that matches the assembly code listed below:

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x1c0,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  mov    $0x0,%eax
  call   <rin@plt>
  mov    %eax,-0x1b4(%rbp)
  jmp    L40
L102:
  movl   $0x1,-0x1a8(%rbp)
  movl   $0x0,-0x1ac(%rbp)
  mov    $0x0,%eax
  call   <rin@plt>
  mov    %eax,-0x1a4(%rbp)
  movl   $0x0,-0x1b0(%rbp)
  jmp    L28
L79:
  mov    $0x0,%eax
  call   <rin@plt>
  mov    -0x1b0(%rbp),%edx
  movslq %edx,%rdx
  mov    %eax,-0x1a0(%rbp,%rdx,4)
  addl   $0x1,-0x1b0(%rbp)
L28:
  mov    -0x1b0(%rbp),%eax
  cmp    -0x1a4(%rbp),%eax
  jl     L79
  movl   $0x0,-0x1b0(%rbp)
  jmp    L92
L78:
  mov    -0x1b0(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%edx
  mov    -0x1a4(%rbp),%eax
  sub    -0x1b0(%rbp),%eax
  sub    $0x1,%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  cmp    %eax,%edx
  jne    L43
  mov    -0x1b0(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  sub    -0x1ac(%rbp),%eax
  cmp    $0x1,%eax
  jle    L181
L43:
  movl   $0x0,-0x1a8(%rbp)
  jmp    L101
L181:
  mov    -0x1b0(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  mov    %eax,-0x1ac(%rbp)
  addl   $0x1,-0x1b0(%rbp)
L92:
  mov    -0x1a4(%rbp),%eax
  sar    %eax
  cmp    %eax,-0x1b0(%rbp)
  jl     L78
L101:
  cmpl   $0x0,-0x1a8(%rbp)
  jne    L10
  lea    D25(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  jmp    L40
L10:
  mov    -0x1a4(%rbp),%eax
  and    $0x1,%eax
  test   %eax,%eax
  je     L107
  mov    -0x1b0(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  sub    -0x1ac(%rbp),%eax
  cmp    $0x1,%eax
  jg     L23
  mov    -0x1b0(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  cmp    $0x7,%eax
  je     L144
L23:
  lea    D25(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  jmp    L40
L144:
  lea    D40(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  jmp    L40
L107:
  mov    -0x1b0(%rbp),%eax
  cltq
  mov    -0x1a0(%rbp,%rax,4),%eax
  cmp    $0x7,%eax
  je     L5
  lea    D25(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  jmp    L40
L5:
  lea    D40(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
L40:
  mov    -0x1b4(%rbp),%eax
  lea    -0x1(%rax),%edx
  mov    %edx,-0x1b4(%rbp)
  test   %eax,%eax
  jne    L102
  mov    $0x0,%eax
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L14
  call   <__stack_chk_fail@plt>
L14:
  leave
  ret
```

tool_calls: name: read_data
arguments: data_label: D25
type: string
name: read_data
arguments: data_label: D40
type: string

tool: D25: no


tool: D40: yes


assistant: ```c
int main() {
  int T = rin(), n, i, prev, flag;
  int num[100];
  while (T--) {
    flag = 1;
    prev = 0;
    n = rin();
    for (i = 0; i < n; i++)
      num[i] = rin();
    for (i = 0; i < (n >> 1); i++) {
      if (num[i] != num[n - i - 1] || (num[i] - prev) > 1) {
        flag = 0;
        break;
      }
      prev = num[i];
    }
    if (!flag)
      printf("no\n");
    else {
      if (n & 1) {
        if (num[i] - prev > 1 || num[i] != 7)
          printf("no\n");
        else
          printf("yes\n");
      } else {
        if (num[i] != 7)
          printf("no\n");
        else
          printf("yes\n");
      }
    }
  }
  return 0;
}
```