user: 请从给定的汇编指令推导出C源代码:

```asm
<ask_menu_selection>:
  endbr64
  push   %r13
  push   %r12
  push   %rbp
  mov    %rsi,%rbp
  push   %rbx
  mov    %rdi,%rbx
  lea    D136(%rip),%rdi
  sub    $0x18,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x8(%rsp)
  xor    %eax,%eax
  call   <printf@plt>
  lea    D112(%rip),%rdi
  call   <printf@plt>
  lea    D124(%rip),%rdi
  call   <printf@plt>
  lea    D35(%rip),%rdi
  call   <printf@plt>
  lea    D21(%rip),%rdi
  call   <printf@plt>
  lea    D88(%rip),%rdi
  call   <printf@plt>
  lea    D101(%rip),%rdi
  call   <printf@plt>
  lea    D89(%rip),%rdi
  call   <printf@plt>
  lea    D0(%rip),%rdi
  call   <printf@plt>
  lea    D25(%rip),%rdi
  call   <printf@plt>
  lea    D54(%rip),%rdi
  call   <printf@plt>
  mov    %rbx,%rsi
  lea    D68(%rip),%rdi
  xor    %eax,%eax
  call   <scanf@plt>
  mov    (%rbx),%eax
  cmp    $0x5,%eax
  jle    L18
L7:
  cmp    $0x9,%eax
  jne    L12
  movl   $0x1,0x0(%rbp)
L12:
  mov    0x8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L35
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  ret
  nopw   0x0(%rax,%rax,1)
L18:
  lea    0x7(%rsp),%r13
  lea    D2(%rip),%r12
  lea    D28(%rip),%rdi
  call   <printf@plt>
  mov    %r13,%rsi
  mov    %r12,%rdi
  xor    %eax,%eax
  call   <scanf@plt>
  mov    %r13,%rsi
  mov    %r12,%rdi
  xor    %eax,%eax
  call   <scanf@plt>
  mov    %r13,%rsi
  mov    %r12,%rdi
  xor    %eax,%eax
  movl   $0x1,0x0(%rbp)
  movb   $0x79,0x7(%rsp)
  call   <scanf@plt>
  mov    (%rbx),%eax
  jmp    L7
L35:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: label: D136
data_type: string
name: extract_symbolic_data
arguments: label: D112
data_type: string
name: extract_symbolic_data
arguments: label: D124
data_type: string
name: extract_symbolic_data
arguments: label: D35
data_type: string
name: extract_symbolic_data
arguments: label: D21
data_type: string
name: extract_symbolic_data
arguments: label: D88
data_type: string
name: extract_symbolic_data
arguments: label: D101
data_type: string
name: extract_symbolic_data
arguments: label: D89
data_type: string
name: extract_symbolic_data
arguments: label: D0
data_type: string
name: extract_symbolic_data
arguments: label: D25
data_type: string
name: extract_symbolic_data
arguments: label: D54
data_type: string
name: extract_symbolic_data
arguments: label: D68
data_type: string
name: extract_symbolic_data
arguments: label: D2
data_type: string
name: extract_symbolic_data
arguments: label: D28
data_type: string

tool: D136: 
MENU for type of start system and homotopy :


tool: D112:   1. start system is based on total degree;


tool: D124:   2. a linear-product start system will be given;


tool: D35:   3. start system and start solutions are provided;


tool: D21:   4. the homotopy is a cascade to go one level down;


tool: D88:   5. diagonal homotopy to start a cascade;


tool: D101:   6. compute witness set for a hypersurface;


tool: D89:   7. collapse extrinsic diagonal of a witness set;


tool: D0:   8. remove the last slack variable of a witness set;


tool: D25:   9. test the crude path trackers.


tool: D54: Type 1, 2, 3, 4, 5, 6, 7, 8, or 9 to select : 

tool: D68: %d

tool: D2: %c

tool: D28: 
Do you want to monitor progress of solver on screen ? (y/n) 

assistant: ```c
void ask_menu_selection(int *kind, int *monitor) {
  char ans;
  printf("\nMENU for type of start system and homotopy :\n");
  printf("  1. start system is based on total degree;\n");
  printf("  2. a linear-product start system will be given;\n");
  printf("  3. start system and start solutions are provided;\n");
  printf("  4. the homotopy is a cascade to go one level down;\n");
  printf("  5. diagonal homotopy to start a cascade;\n");
  printf("  6. compute witness set for a hypersurface;\n");
  printf("  7. collapse extrinsic diagonal of a witness set;\n");
  printf("  8. remove the last slack variable of a witness set;\n");
  printf("  9. test the crude path trackers.\n");
  printf("Type 1, 2, 3, 4, 5, 6, 7, 8, or 9 to select : ");
  scanf("%d", kind);
  if (*kind < 6) {
    printf("\nDo you want to monitor progress of solver on screen ? (y/n) ");
    scanf("%c", &ans);
    scanf("%c", &ans);
    if (ans = 'y')
      *monitor = 1;
    else
      *monitor = 0;
    scanf("%c", &ans);
  }
  if (*kind == 9)
    *monitor = 1;
}
```