user: Please show me the C implementation that matches the assembly code listed below:

```asm
<main>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x88,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x78(%rsp)
  xor    %eax,%eax
  test   %edi,%edi
  jle    L116
  mov    %edi,%ebp
  mov    %rsi,%r12
  xor    %ebx,%ebx
  nopl   0x0(%rax)
L19:
  lea    D61(%rip),%rdi
  call   <puts@plt>
  movslq %ebx,%rax
  add    $0x1,%ebx
  lea    D128(%rip),%rdi
  mov    (%r12,%rax,8),%rax
  movslq %ebx,%rbx
  movsbl (%rax),%esi
  xor    %eax,%eax
  call   <printf@plt>
  mov    -0x8(%r12,%rbx,8),%rax
  lea    -0x1(%rbx),%esi
  cmpb   $0x2d,(%rax)
  jne    L77
  nopl   0x0(%rax,%rax,1)
L128:
  movsbl 0x1(%rax),%edi
  cmp    $0x6e,%dil
  je     L118
  call   <isdigit@plt>
  test   %eax,%eax
  jne    L39
  mov    %ebx,%r13d
  lea    D14(%rip),%rdi
  movslq %ebx,%rbx
  mov    $0xffffffff,%ebp
  call   <puts@plt>
  mov    (%r12,%rbx,8),%r8
  mov    %r13d,%ecx
  mov    %r13d,%esi
  mov    $0xffffffff,%edx
  lea    D15(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  lea    D99(%rip),%rdi
  call   <puts@plt>
L109:
  mov    %r13d,%esi
  lea    D133(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    %ebp,%esi
  lea    D108(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    (%r12),%rsi
  lea    D150(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
L116:
  mov    0x78(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L87
  add    $0x88,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  xchg   %ax,%ax
L118:
  lea    D66(%rip),%rdi
  call   <puts@plt>
L119:
  mov    (%r12,%rbx,8),%r8
  sub    $0x1,%ebp
  mov    %ebx,%ecx
  mov    %ebx,%esi
  mov    %ebp,%edx
  lea    D15(%rip),%rdi
  xor    %eax,%eax
  mov    %ebx,%r13d
  call   <printf@plt>
  lea    D99(%rip),%rdi
  add    $0x1,%rbx
  call   <puts@plt>
  test   %ebp,%ebp
  je     L109
  mov    -0x8(%r12,%rbx,8),%rax
  lea    -0x1(%rbx),%esi
  cmpb   $0x2d,(%rax)
  je     L128
L77:
  lea    D133(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    %ebp,%esi
  lea    D108(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    (%r12),%rsi
  xor    %eax,%eax
  lea    D150(%rip),%rdi
  call   <printf@plt>
  sub    $0x1,%ebp
  jne    L19
  jmp    L116
  nopl   0x0(%rax)
L39:
  lea    D148(%rip),%rdi
  xor    %r13d,%r13d
  call   <puts@plt>
  lea    0x10(%rsp),%rdi
  mov    $0x5,%esi
  mov    %rdi,(%rsp)
  call   <clear_line@plt>
  mov    %ebp,0xc(%rsp)
  jmp    L102
L121:
  test   %r15b,%r15b
  je     L38
  cmp    $0xa,%r15b
  je     L38
  mov    (%rsp),%rax
  mov    %r15d,%edx
  mov    %ebp,%esi
  lea    D140(%rip),%rdi
  mov    %r14b,(%rax,%r13,1)
  xor    %eax,%eax
  add    $0x1,%r13
  call   <printf@plt>
L102:
  mov    (%r12),%rax
  mov    %r13d,%ebp
  movsbl (%rax,%r13,1),%r15d
  mov    %r15d,%edi
  mov    %r15d,%r14d
  call   <isdigit@plt>
  test   %eax,%eax
  jne    L121
L38:
  mov    (%rsp),%rdi
  mov    %ebp,%r15d
  mov    0xc(%rsp),%ebp
  movslq %r15d,%rsi
  movb   $0x0,0x10(%rsp,%rsi,1)
  call   <atoi@plt>
  lea    D144(%rip),%rdi
  movsbl %al,%esi
  xor    %eax,%eax
  call   <printf@plt>
  jmp    L119
L87:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: read_data
arguments: tag: D61
type_infered: string
name: read_data
arguments: tag: D128
type_infered: string
name: read_data
arguments: tag: D14
type_infered: string
name: read_data
arguments: tag: D15
type_infered: string
name: read_data
arguments: tag: D99
type_infered: string
name: read_data
arguments: tag: D133
type_infered: string
name: read_data
arguments: tag: D108
type_infered: string
name: read_data
arguments: tag: D150
type_infered: string
name: read_data
arguments: tag: D66
type_infered: string
name: read_data
arguments: tag: D148
type_infered: string
name: read_data
arguments: tag: D140
type_infered: string
name: read_data
arguments: tag: D144
type_infered: string

tool: D61: ============================================

tool: D128: * ( * ( argv + i ) ) = %c;


tool: D14: wrong parameter;

tool: D15: in second while i = %d; argc = %d; * ( argv + %d ) = %s;


tool: D99: ----------------------

tool: D133: after ( while c == '-' ) i = %d;

tool: D108:  argc = %d;

tool: D150:  * argv = %s;


tool: D66: numeric = 1;

tool: D148: Yahooo!!! It's digit! ))

tool: D140: tmp_line [ %d ] = %c;


tool: D144: getted pos_1 = %d;


assistant: ```c
int main(int argc, char *argv[]) {
  char numeric = 0;
  char pos_1 = 0;
  char c = 0;
  int i = 0;
  int j = 0;
  int k = 0;
  char tmp_line[100];
  while (argc > 0) {
    printf("============================================\n");
    printf("* ( * ( argv + i ) ) = %c;\n", *(*(argv + i)));
    while (argc > 0 && (c = *(*(argv + i))) == '-') {
      c = *(*(argv + i) + 1);
      switch (c) {
      case 'n':
        numeric = 1;
        printf("numeric = 1;\n");
        break;
      default:
        if (isdigit(c)) {
          printf("Yahooo!!! It's digit! ))\n");
          j = 0;
          k = 0;
          clear_line(tmp_line, 5);
          while (isdigit(c = *((*argv) + j)) && c != '\0' && c != '\n') {
            tmp_line[k] = c;
            printf("tmp_line [ %d ] = %c;\n", k, tmp_line[k]);
            k++;
            j++;
          }
          tmp_line[k] = '\0';
          pos_1 = atoi(tmp_line);
          printf("getted pos_1 = %d;\n", pos_1);
        } else {
          printf("wrong parameter;\n");
          argc = 0;
        }
        break;
      }
      i++;
      argc--;
      printf("in second while i = %d; argc = %d; * ( argv + %d ) = %s;\n", i, argc, i, *(argv + i));
      printf("----------------------\n");
    }
    printf("after ( while c == '-' ) i = %d;", i);
    printf(" argc = %d;", argc);
    printf(" * argv = %s;\n", *argv);
    if (argc > 0) {
      i++;
      argc--;
    }
  }
  return 0;
}
```