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

```asm
<main>:
  endbr64
  push   %r15
  xor    %edi,%edi
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x8(%rsp)
  xor    %eax,%eax
  call   <time@plt>
  mov    %eax,%edi
  call   <srand@plt>
  xor    %eax,%eax
  call   <rand@plt>
  movslq %eax,%rbp
  cltd
  imul   $0x66666667,%rbp,%rbp
  sar    $0x22,%rbp
  sub    %edx,%ebp
  lea    0x0(%rbp,%rbp,4),%edx
  add    %edx,%edx
  sub    %edx,%eax
  mov    %eax,%ebp
  mov    %eax,%r13d
  nopl   (%rax)
L164:
  xor    %eax,%eax
  call   <rand@plt>
  movslq %eax,%rdx
  mov    %eax,%ecx
  imul   $0x66666667,%rdx,%rdx
  sar    $0x1f,%ecx
  sar    $0x22,%rdx
  sub    %ecx,%edx
  lea    (%rdx,%rdx,4),%edx
  add    %edx,%edx
  sub    %edx,%eax
  movsbl %al,%ebx
  cmp    %al,%r13b
  je     L164
  nopl   0x0(%rax,%rax,1)
L49:
  xor    %eax,%eax
  call   <rand@plt>
  movslq %eax,%rdx
  mov    %eax,%ecx
  imul   $0x66666667,%rdx,%rdx
  sar    $0x1f,%ecx
  sar    $0x22,%rdx
  sub    %ecx,%edx
  lea    (%rdx,%rdx,4),%edx
  add    %edx,%edx
  sub    %edx,%eax
  movsbl %al,%r12d
  cmp    %al,%r13b
  je     L49
  cmp    %al,%bl
  je     L49
  lea    0x4(%rsp),%r14
  lea    D14(%rip),%r13
  mov    $0xcccccccd,%r15d
  nopw   0x0(%rax,%rax,1)
L88:
  mov    %r14,%rsi
  mov    %r13,%rdi
  call   <scanf@plt>
  mov    0x4(%rsp),%edx
  lea    -0xc(%rdx),%eax
  cmp    $0x3cf,%eax
  ja     L88
  movslq %edx,%rax
  mov    %edx,%edi
  mov    %edx,%esi
  imul   $0x51eb851f,%rax,%rcx
  sar    $0x1f,%edi
  imul   $0x66666667,%rax,%rax
  sar    $0x25,%rcx
  sub    %edi,%ecx
  sar    $0x22,%rax
  imul   $0x64,%ecx,%r8d
  sub    %edi,%eax
  lea    (%rax,%rax,4),%edi
  mov    %edx,%eax
  add    %edi,%edi
  sub    %r8d,%esi
  sub    %edi,%eax
  imul   %r15,%rsi
  shr    $0x23,%rsi
  cmp    %eax,%esi
  sete   %dl
  cmp    %esi,%ecx
  sete   %dil
  or     %dil,%dl
  jne    L88
  cmp    %eax,%ecx
  je     L88
  cmp    %ecx,%ebp
  je     L112
  movl   $0x0,0x4(%rsp)
  xor    %r8d,%r8d
L199:
  cmp    %ebx,%ecx
  sete   %dl
  cmp    %r12d,%ecx
  sete   %cl
  or     %ecx,%edx
  movzbl %dl,%edx
  cmp    %ebx,%esi
  je     L87
  cmp    %r12d,%eax
  je     L157
L207:
  cmp    %ebx,%esi
  je     L189
  cmp    %esi,%ebp
  je     L189
  cmp    %ebx,%eax
  je     L3
L130:
  cmp    %eax,%ebp
  je     L3
  cmp    $0x3,%r8d
  je     L101
L109:
  mov    %r8d,%esi
  lea    D2(%rip),%rdi
  call   <printf@plt>
  jmp    L88
  nop
L87:
  add    $0x1,%r8d
  mov    %r8d,0x4(%rsp)
  cmp    %r12d,%eax
  je     L157
L189:
  add    $0x1,%edx
  cmp    %ebx,%eax
  jne    L130
L3:
  add    $0x1,%edx
  cmp    $0x3,%r8d
  jne    L109
L101:
  lea    D25(%rip),%rdi
  call   <puts@plt>
  mov    0x8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L78
  add    $0x18,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L157:
  add    $0x1,%r8d
  mov    %r8d,0x4(%rsp)
  jmp    L207
  xchg   %ax,%ax
L112:
  movl   $0x1,0x4(%rsp)
  mov    $0x1,%r8d
  jmp    L199
L78:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: label: D14
type_guessed: string
name: extract_symbolic_data
arguments: label: D2
type_guessed: string
name: extract_symbolic_data
arguments: label: D25
type_guessed: string

tool: D14: %3d

tool: D2: %d-%d


tool: D25: Hit!


assistant: ```c
int main() {
  char x, y, z;
  int a, b, c;
  int n, m;
  srand((unsigned int)time(NULL));
  x = (char)(rand() % 10);
  do {
    y = (char)(rand() % 10);
  } while (y == x);
  do {
    z = (char)(rand() % 10);
  } while (z == x || z == y);
  for (;;) {
    scanf("%3d", &n);
    a = n / 100;
    b = n % 100 / 10;
    c = n % 10;
    if (n < 12 || n > 987 || a == b || a == c || b == c)
      continue;
    n = 0;
    if (a == x)
      n++;
    if (b == y)
      n++;
    if (c == z)
      n++;
    m = 0;
    if (a == y || a == z)
      m++;
    if (b == x || b == y)
      m++;
    if (c == x || c == y)
      m++;
    if (n != 3)
      printf("%d-%d\n", n, m);
    else {
      puts("Hit!\n");
      break;
    }
  }
  return 0;
}
```