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

```asm
<main>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x8(%rsp)
  xor    %eax,%eax
  lea    D18(%rip),%rdi
  call   <printf@plt>
  mov    %rsp,%rsi
  lea    D34(%rip),%rdi
  call   <scanf@plt>
  mov    $0xa,%edi
  call   <putchar@plt>
  mov    (%rsp),%rax
  test   %rax,%rax
  jle    L75
  mov    $0xd,%r13d
  mov    $0xa,%ebx
  mov    $0x0,%r15d
  jmp    L149
L45:
  lea    (%rbx,%rbx,4),%rbp
  add    %rbp,%rbp
  mov    (%rsp),%rax
  cqto
  idiv   %rbp
  mov    %rdx,%rdi
  mov    %rbx,%rsi
  call   <check@plt>
  cmp    %rax,(%rsp)
  je     L104
  mov    %r12,%rsi
  lea    D54(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  sub    $0x1,%r13d
  je     L19
  mov    %rbp,%rbx
L149:
  mov    %r14,%rcx
  mov    (%rsp),%rax
  cqto
  idiv   %rbx
  mov    %rdx,%rdi
  mov    %rdx,%r14
  mov    %r15,%r12
  cmp    %rcx,%rdx
  je     L45
  movabs $0x6666666666666667,%rax
  imul   %rbx
  sar    $0x2,%rdx
  mov    %rbx,%rax
  sar    $0x3f,%rax
  sub    %rax,%rdx
  mov    %rdx,%rsi
  call   <check@plt>
  mov    %rax,%r12
  jmp    L45
L104:
  mov    %r12,%rsi
  lea    D54(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
L19:
  lea    D78(%rip),%rdi
  call   <puts@plt>
  mov    0x8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L31
  mov    $0x0,%eax
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L75:
  je     L138
  mov    $0xd,%r12d
  mov    $0xfffffffffffffff6,%rbx
  mov    $0x0,%r15d
  movabs $0x6666666666666667,%r13
  jmp    L27
L138:
  lea    D65(%rip),%rdi
  call   <puts@plt>
  jmp    L19
L120:
  lea    (%rbx,%rbx,4),%rsi
  add    %rsi,%rsi
  mov    %rsi,%rbx
  mov    (%rsp),%rax
  cqto
  idiv   %rsi
  neg    %rdx
  mov    %rdx,%rdi
  mov    %rsi,%rax
  imul   %r13
  sar    $0x2,%rdx
  sar    $0x3f,%rsi
  sub    %rdx,%rsi
  call   <check@plt>
  add    (%rsp),%rax
  je     L109
  mov    %rbp,%rsi
  lea    D54(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  sub    $0x1,%r12d
  je     L19
L27:
  mov    %r14,%rcx
  mov    (%rsp),%rax
  cqto
  idiv   %rbx
  mov    %rdx,%rdi
  mov    %rdx,%r14
  mov    %r15,%rbp
  cmp    %rcx,%rdx
  je     L120
  mov    %rbx,%rax
  imul   %r13
  sar    $0x2,%rdx
  mov    %rbx,%rsi
  sar    $0x3f,%rsi
  sub    %rdx,%rsi
  neg    %rdi
  call   <check@plt>
  mov    %rax,%rbp
  jmp    L120
L109:
  mov    %rbp,%rsi
  lea    D33(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L19
L31:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D18
data_type: string
name: extract_symbolic_data
arguments: data_label: D34
data_type: string
name: extract_symbolic_data
arguments: data_label: D54
data_type: string
name: extract_symbolic_data
arguments: data_label: D78
data_type: string
name: extract_symbolic_data
arguments: data_label: D65
data_type: string
name: extract_symbolic_data
arguments: data_label: D33
data_type: string

tool: D18: 
Enter an ingteger > 

tool: D34: %lld

tool: D54: %lld


tool: D78: That's all, have a nice day!

tool: D65: 0

tool: D33: -%lld


assistant: ```c
int main() {
  long long int in, num, digit, temp, lost, value;
  int a = 0;
  printf("\nEnter an ingteger > ");
  scanf("%lld", &in);
  printf("\n");
  if (in > 0) {
    num = 10;
    while (a <= 12) {
      value = in % num;
      if (lost == value) {
        digit = 0;
      } else {
        digit = check(value, (num / 10));
      }
      lost = value;
      num = num * 10;
      temp = in % num;
      temp = check(temp, (num / 10));
      if (temp == in) {
        printf("%lld\n", digit);
        break;
      } else {
        printf("%lld\n", digit);
      }
      a++;
    }
  } else if (in == 0) {
    printf("0\n");
  } else {
    num = (-10);
    while (a <= 12) {
      value = in % (num);
      if (lost == value) {
        digit = 0;
      } else {
        digit = check((-value), (-(num / 10)));
      }
      lost = value;
      num = num * 10;
      temp = in % num;
      temp = check((-temp), (-(num / 10)));
      if (temp == (-in)) {
        printf("-%lld\n", digit);
        break;
      } else {
        printf("%lld\n", digit);
      }
      a++;
    }
  }
  printf("That's all, have a nice day!\n");
  return 0;
}
```