user: 请将以下的汇编代码转换成C语言代码：

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x30,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  mov    $0x0,%edi
  call   <time@plt>
  mov    %eax,%edi
  call   <srand@plt>
  movl   $0x0,-0x18(%rbp)
  movl   $0x0,-0x14(%rbp)
  mov    $0xa,%esi
  lea    D42(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
L18:
  mov    $0x0,%eax
  call   <rand@plt>
  movslq %eax,%rdx
  imul   $0x51eb851f,%rdx,%rdx
  shr    $0x20,%rdx
  sar    $0x5,%edx
  mov    %eax,%ecx
  sar    $0x1f,%ecx
  sub    %ecx,%edx
  imul   $0x64,%edx,%ecx
  sub    %ecx,%eax
  mov    %eax,%edx
  lea    0x1(%rdx),%eax
  mov    %eax,-0xc(%rbp)
  movl   $0x0,-0x20(%rbp)
  mov    $0x64,%esi
  lea    D24(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movl   $0x0,-0x1c(%rbp)
  jmp    L34
L72:
  lea    D93(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  lea    -0x20(%rbp),%rax
  mov    %rax,%rsi
  lea    D15(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  movss  D82(%rip),%xmm0
  movss  %xmm0,-0x10(%rbp)
  jmp    L46
L95:
  lea    D12(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movss  -0x10(%rbp),%xmm0
  movss  D106(%rip),%xmm1
  divss  %xmm1,%xmm0
  movss  %xmm0,-0x10(%rbp)
L46:
  movss  -0x10(%rbp),%xmm0
  cvttss2si %xmm0,%edx
  mov    -0x20(%rbp),%eax
  sub    -0xc(%rbp),%eax
  mov    %eax,%ecx
  neg    %ecx
  cmovns %ecx,%eax
  cmp    %eax,%edx
  jg     L95
  addl   $0x1,-0x1c(%rbp)
L34:
  cmpl   $0x9,-0x1c(%rbp)
  jg     L86
  mov    -0x20(%rbp),%eax
  cmp    %eax,-0xc(%rbp)
  jne    L72
L86:
  mov    -0x20(%rbp),%eax
  cmp    %eax,-0xc(%rbp)
  je     L66
  mov    -0xc(%rbp),%eax
  mov    %eax,%edx
  mov    $0xa,%esi
  lea    D79(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  addl   $0x1,-0x14(%rbp)
  jmp    L36
L66:
  lea    D97(%rip),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  addl   $0x1,-0x18(%rbp)
L36:
  lea    D67(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  nop
L26:
  mov    $0x0,%eax
  call   <getchar@plt>
  mov    %al,-0x21(%rbp)
  movsbl -0x21(%rbp),%eax
  mov    %eax,%edi
  call   <isalpha@plt>
  test   %eax,%eax
  je     L26
  movsbl -0x21(%rbp),%eax
  mov    %eax,%edi
  call   <tolower@plt>
  cmp    $0x6e,%al
  jne    L18
  mov    -0x18(%rbp),%eax
  imul   $0x64,%eax,%eax
  mov    -0x18(%rbp),%ecx
  mov    -0x14(%rbp),%edx
  lea    (%rdx,%rcx,1),%esi
  cltd
  idiv   %esi
  mov    %eax,%ecx
  mov    -0x18(%rbp),%edx
  mov    -0x14(%rbp),%eax
  add    %eax,%edx
  mov    -0x18(%rbp),%eax
  mov    %eax,%esi
  lea    D87(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%edi
  call   <exit@plt>
  mov    $0x0,%eax
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L45
  call   <__stack_chk_fail@plt>
L45:
  leave
  ret
```

tool_calls: name: retrieve_data
arguments: label: D42
type: string
name: retrieve_data
arguments: label: D24
type: string
name: retrieve_data
arguments: label: D93
type: string
name: retrieve_data
arguments: label: D15
type: string
name: retrieve_data
arguments: label: D82
type: byte[4]
name: retrieve_data
arguments: label: D12
type: string
name: retrieve_data
arguments: label: D106
type: byte[4]
name: retrieve_data
arguments: label: D79
type: string
name: retrieve_data
arguments: label: D97
type: string
name: retrieve_data
arguments: label: D67
type: string
name: retrieve_data
arguments: label: D87
type: string

tool: D42: Seeing Stars
------------
This is a number guessing game with a twist. After every guess you
will be given a number of stars to tell you how close you are to the
number you are trying to guess. The more stars you see, the closer
you are.
You only have %d guesses, so think quick.



tool: D24: 
I'm thinking of a number between 1 and %d.

tool: D93: 
What is your guess? 

tool: D15: %d

tool: {"D82": [0x00,0x00,0xc8,0x42]}

tool: D12: **

tool: {"D106": [0x00,0x00,0x00,0x40]}

tool: D79: 
Sorry, thats %d guesses. My number was %d.


tool: D97: ******
Bingo! You got my number.

tool: D67: Do you want to play again? (y/n) 

tool: D87: 
Well then, you won %d out of %d games, or %d%%.


assistant: ```c
int main() {
  int goal, guess, c, wins, loses;
  char yesno;
  float d;
  srand(time(NULL));
  wins = 0;
  loses = 0;
  printf("Seeing Stars\n------------\n"
         "This is a number guessing game with a twist. After every guess you\n"
         "will be given a number of stars to tell you how close you are to the\n"
         "number you are trying to guess. The more stars you see, the closer\n"
         "you are.\n"
         "You only have %d guesses, so think quick.\n\n",
         10);
  do {
    goal = rand() % 100 + 1;
    guess = 0;
    printf("\nI'm thinking of a number between 1 and %d.", 100);
    for (c = 0; c < 10 && guess != goal; c++) {
      printf("\nWhat is your guess? ");
      scanf("%d", &guess);
      for (d = 100; (int)d > abs(guess - goal); d /= 2)
        printf("**");
    }
    if (guess != goal) {
      printf("\nSorry, thats %d guesses. My number was %d.\n", 10, goal);
      loses++;
    } else {
      printf("******\nBingo! You got my number.\n");
      wins++;
    }
    printf("Do you want to play again? (y/n) ");
    while (!isalpha(yesno = getchar()))
      ;
  } while (tolower(yesno) != 'n');
  printf("\nWell then, you won %d out of %d games, or %d%%.\n", wins, wins + loses, wins * 100 / (wins + loses));
  exit(0);
}
```