user: 请将这段汇编代码片段转换成等效的C代码：

```asm
<main>:
  endbr64
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  lea    -0x18000(%rsp),%r11
L106:
  sub    $0x1000,%rsp
  orq    $0x0,(%rsp)
  cmp    %r11,%rsp
  jne    L106
  sub    $0x6c8,%rsp
  lea    D22(%rip),%rdi
  mov    %fs:0x28,%rax
  mov    %rax,0x186b8(%rsp)
  xor    %eax,%eax
  lea    0xc(%rsp),%rsi
  call   <scanf@plt>
  mov    0xc(%rsp),%eax
  test   %eax,%eax
  jle    L124
  xor    %ebx,%ebx
  lea    0x10(%rsp),%rbp
  lea    D18(%rip),%r13
  lea    D8(%rip),%r12
  nop
L120:
  mov    %rbp,%rsi
  mov    %r13,%rdi
  xor    %eax,%eax
  call   <scanf@plt>
  mov    %rbp,%rdi
  call   <strlen@plt>
  movdqa D7(%rip),%xmm4
  lea    -0x1(%rax),%edx
  test   %edx,%edx
  jle    L42
  sub    $0x2,%eax
  cmp    $0xe,%eax
  jbe    L186
  mov    %edx,%ecx
  pxor   %xmm1,%xmm1
  pxor   %xmm6,%xmm6
  mov    %rbp,%rax
  shr    $0x4,%ecx
  pxor   %xmm5,%xmm5
  sub    $0x1,%ecx
  shl    $0x4,%rcx
  lea    0x20(%rsp,%rcx,1),%rcx
  nopl   0x0(%rax)
L191:
  movdqu 0x1(%rax),%xmm0
  movdqa %xmm6,%xmm3
  add    $0x10,%rax
  pcmpeqb -0x10(%rax),%xmm0
  pand   %xmm4,%xmm0
  pcmpgtb %xmm0,%xmm3
  movdqa %xmm0,%xmm2
  punpcklbw %xmm3,%xmm2
  punpckhbw %xmm3,%xmm0
  movdqa %xmm5,%xmm3
  pcmpgtw %xmm2,%xmm3
  movdqa %xmm2,%xmm7
  punpcklwd %xmm3,%xmm7
  punpckhwd %xmm3,%xmm2
  movdqa %xmm0,%xmm3
  paddd  %xmm7,%xmm1
  paddd  %xmm2,%xmm1
  movdqa %xmm5,%xmm2
  pcmpgtw %xmm0,%xmm2
  punpcklwd %xmm2,%xmm3
  punpckhwd %xmm2,%xmm0
  paddd  %xmm3,%xmm1
  paddd  %xmm0,%xmm1
  cmp    %rax,%rcx
  jne    L191
  movdqa %xmm1,%xmm0
  mov    %edx,%eax
  psrldq $0x8,%xmm0
  and    $0xfffffff0,%eax
  paddd  %xmm0,%xmm1
  movdqa %xmm1,%xmm0
  psrldq $0x4,%xmm0
  paddd  %xmm0,%xmm1
  movd   %xmm1,%esi
  test   $0xf,%dl
  je     L175
L192:
  lea    0x1(%rax),%ecx
  movslq %eax,%r8
  movslq %ecx,%rdi
  movzbl 0x10(%rsp,%rdi,1),%edi
  cmp    %dil,0x10(%rsp,%r8,1)
  jne    L75
  add    $0x1,%esi
L75:
  cmp    %ecx,%edx
  jle    L175
  lea    0x2(%rax),%ecx
  movslq %ecx,%r8
  movzbl 0x10(%rsp,%r8,1),%r8d
  cmp    %dil,%r8b
  sete   %dil
  movzbl %dil,%edi
  add    %edi,%esi
  cmp    %edx,%ecx
  jge    L175
  lea    0x3(%rax),%ecx
  movslq %ecx,%rdi
  movzbl 0x10(%rsp,%rdi,1),%edi
  cmp    %dil,%r8b
  sete   %r8b
  movzbl %r8b,%r8d
  add    %r8d,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0x4(%rax),%ecx
  movslq %ecx,%r8
  movzbl 0x10(%rsp,%r8,1),%r8d
  cmp    %r8b,%dil
  sete   %dil
  movzbl %dil,%edi
  add    %edi,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0x5(%rax),%ecx
  movslq %ecx,%rdi
  movzbl 0x10(%rsp,%rdi,1),%edi
  cmp    %dil,%r8b
  sete   %r8b
  movzbl %r8b,%r8d
  add    %r8d,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0x6(%rax),%ecx
  movslq %ecx,%r8
  movzbl 0x10(%rsp,%r8,1),%r8d
  cmp    %r8b,%dil
  sete   %dil
  movzbl %dil,%edi
  add    %edi,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0x7(%rax),%ecx
  movslq %ecx,%rdi
  movzbl 0x10(%rsp,%rdi,1),%edi
  cmp    %dil,%r8b
  sete   %r8b
  movzbl %r8b,%r8d
  add    %r8d,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0x8(%rax),%ecx
  movslq %ecx,%r8
  movzbl 0x10(%rsp,%r8,1),%r8d
  cmp    %r8b,%dil
  sete   %dil
  movzbl %dil,%edi
  add    %edi,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0x9(%rax),%ecx
  movslq %ecx,%rdi
  movzbl 0x10(%rsp,%rdi,1),%edi
  cmp    %dil,%r8b
  sete   %r8b
  movzbl %r8b,%r8d
  add    %r8d,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0xa(%rax),%ecx
  movslq %ecx,%r8
  movzbl 0x10(%rsp,%r8,1),%r8d
  cmp    %r8b,%dil
  sete   %dil
  movzbl %dil,%edi
  add    %edi,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0xb(%rax),%ecx
  movslq %ecx,%rdi
  movzbl 0x10(%rsp,%rdi,1),%edi
  cmp    %dil,%r8b
  sete   %r8b
  movzbl %r8b,%r8d
  add    %r8d,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0xc(%rax),%ecx
  movslq %ecx,%r8
  movzbl 0x10(%rsp,%r8,1),%r8d
  cmp    %r8b,%dil
  sete   %dil
  movzbl %dil,%edi
  add    %edi,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0xd(%rax),%ecx
  movslq %ecx,%rdi
  movzbl 0x10(%rsp,%rdi,1),%edi
  cmp    %dil,%r8b
  sete   %r8b
  movzbl %r8b,%r8d
  add    %r8d,%esi
  cmp    %ecx,%edx
  jle    L175
  lea    0xe(%rax),%ecx
  movslq %ecx,%r8
  movzbl 0x10(%rsp,%r8,1),%r8d
  cmp    %r8b,%dil
  sete   %dil
  movzbl %dil,%edi
  add    %edi,%esi
  cmp    %ecx,%edx
  jle    L175
  add    $0xf,%eax
  cltq
  cmp    %r8b,0x10(%rsp,%rax,1)
  jne    L175
  add    $0x1,%esi
  nopl   0x0(%rax,%rax,1)
L175:
  mov    %r12,%rdi
  add    $0x1,%ebx
  call   <printf@plt>
  cmp    %ebx,0xc(%rsp)
  jg     L120
L124:
  mov    0x186b8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L193
  add    $0x186c8,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
L42:
  xor    %esi,%esi
  jmp    L175
L186:
  xor    %esi,%esi
  xor    %eax,%eax
  jmp    L192
L193:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: data_label: D22
type: string
name: disassemble_data
arguments: data_label: D18
type: string
name: disassemble_data
arguments: data_label: D8
type: string
name: disassemble_data
arguments: data_label: D7
type: byte[16]

tool: D22: %d

tool: D18: %s

tool: D8: %d


tool: {"D7": [0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01]}

assistant: ```c
int main() {
  int t, i, j, k, l, count = 0, d, e, n;
  char a[100000];
  scanf("%d", &t);
  for (i = 0; i < t; i++) {
    scanf("%s", a);
    l = strlen(a);
    for (j = 0; j < l - 1; j++) {
      if (a[j] == a[j + 1]) {
        count++;
      }
    }
    printf("%d\n", count);
    count = 0;
  }
  return 0;
}
```