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

```asm
<main>:
  endbr64
  push   %r15
  lea    D13(%rip),%r15
  push   %r14
  lea    D85(%rip),%r14
  push   %r13
  lea    D84(%rip),%r13
  push   %r12
  lea    D80(%rip),%r12
  push   %rbp
  lea    D59(%rip),%rbp
  push   %rbx
  lea    D91(%rip),%rbx
  sub    $0x28,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x18(%rsp)
  xor    %eax,%eax
  lea    0x14(%rsp),%rax
  mov    %rax,0x8(%rsp)
  jmp    L40
  nopl   0x0(%rax,%rax,1)
L8:
  cmp    $0x1,%eax
  jne    L96
  lea    D115(%rip),%rdi
  call   <printf@plt>
  nopl   0x0(%rax)
L96:
  lea    D10(%rip),%rdi
  call   <printf@plt>
  lea    D70(%rip),%rdi
  call   <system@plt>
  mov    0x14(%rsp),%eax
  test   %eax,%eax
  je     L11
L40:
  mov    %r15,%rdi
  call   <system@plt>
  mov    %r14,%rdi
  call   <printf@plt>
  mov    %r13,%rdi
  call   <printf@plt>
  mov    %r12,%rdi
  call   <printf@plt>
  mov    %rbp,%rdi
  call   <printf@plt>
  mov    %rbx,%rdi
  call   <printf@plt>
  mov    0x8(%rsp),%rsi
  lea    D110(%rip),%rdi
  call   <scanf@plt>
  mov    0x14(%rsp),%eax
  cmp    $0x2,%eax
  je     L50
  jg     L37
  test   %eax,%eax
  jne    L8
  lea    D98(%rip),%rdi
  call   <printf@plt>
  xor    %edi,%edi
  call   <exit@plt>
  jmp    L96
  nopl   0x0(%rax,%rax,1)
L37:
  cmp    $0x3,%eax
  jne    L96
  lea    D42(%rip),%rdi
  call   <printf@plt>
  jmp    L96
  nopw   0x0(%rax,%rax,1)
L50:
  lea    D67(%rip),%rdi
  call   <printf@plt>
  jmp    L96
  nopl   0x0(%rax)
L11:
  mov    0x18(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L56
  add    $0x28,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L56:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_tag: D13
type: string
name: extract_symbolic_data
arguments: data_tag: D85
type: string
name: extract_symbolic_data
arguments: data_tag: D84
type: string
name: extract_symbolic_data
arguments: data_tag: D80
type: string
name: extract_symbolic_data
arguments: data_tag: D59
type: string
name: extract_symbolic_data
arguments: data_tag: D91
type: string
name: extract_symbolic_data
arguments: data_tag: D115
type: string
name: extract_symbolic_data
arguments: data_tag: D10
type: string
name: extract_symbolic_data
arguments: data_tag: D70
type: string
name: extract_symbolic_data
arguments: data_tag: D110
type: string
name: extract_symbolic_data
arguments: data_tag: D98
type: string
name: extract_symbolic_data
arguments: data_tag: D42
type: string
name: extract_symbolic_data
arguments: data_tag: D67
type: string

tool: D13: cls

tool: D85: 0-exit


tool: D84: 1-area


tool: D80: 2-gold price


tool: D59: 3-help


tool: D91: please choose one 

tool: D115: area


tool: D10: 


tool: D70: pause

tool: D110: %d

tool: D98: exiting....

tool: D42: help


tool: D67: gold price


assistant: ```c
int main() {
  int ans;
  do {
    system("cls");
    printf("0-exit\n");
    printf("1-area\n");
    printf("2-gold price\n");
    printf("3-help\n");
    printf("please choose one ");
    scanf("%d", &ans);
    switch (ans) {
    case 0:
      printf("exiting....");
      exit(0);
      break;
    case 1:
      printf("area\n");
      break;
    case 2:
      printf("gold price\n");
      break;
    case 3:
      printf("help\n");
      break;
    }
    printf("\n");
    system("pause");
  } while (ans != 0);
  return 0;
}
```