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

```asm
<main>:
  endbr64
  push   %rbx
  sub    $0x20,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x18(%rsp)
  xor    %eax,%eax
  lea    0xe(%rsp),%rbx
  mov    %rbx,%rsi
  lea    D22(%rip),%rdi
  call   <scanf@plt>
  mov    %rbx,%rdi
  call   <strlen@plt>
  lea    -0x1(%rax),%edx
  movslq %edx,%rcx
  movzbl 0xe(%rsp,%rcx,1),%ecx
  cmp    $0x49,%cl
  jne    L208
  sub    $0x2,%eax
  cltq
  mov    $0x0,%esi
L142:
  add    $0x1,%esi
  mov    %eax,%edx
  movzbl 0xe(%rsp,%rax,1),%ecx
  sub    $0x1,%rax
  cmp    $0x49,%cl
  jne    L155
  cmp    $0x2,%esi
  jle    L142
L155:
  cmp    $0x56,%cl
  je     L174
L15:
  movslq %edx,%rax
  cmpb   $0x49,0xe(%rsp,%rax,1)
  je     L93
L249:
  movslq %edx,%rax
  movzbl 0xe(%rsp,%rax,1),%eax
  cmp    $0x58,%al
  jne    L25
  mov    $0x0,%eax
  jmp    L140
L219:
  mov    $0x0,%esi
L174:
  add    $0x5,%esi
  sub    $0x1,%edx
  jmp    L15
L93:
  sub    $0x1,%esi
  sub    $0x1,%edx
  jmp    L249
L168:
  add    $0x9,%esi
  sub    $0x2,%edx
L55:
  movslq %edx,%rcx
  movzbl 0xe(%rsp,%rcx,1),%ecx
  cmp    $0x2,%eax
  jg     L228
  cmp    $0x58,%cl
  jne    L228
L140:
  add    $0x1,%eax
  lea    -0x1(%rdx),%ecx
  movslq %ecx,%rdi
  cmpb   $0x49,0xe(%rsp,%rdi,1)
  je     L168
  add    $0xa,%esi
  mov    %ecx,%edx
  jmp    L55
L228:
  cmp    $0x4c,%cl
  je     L156
L141:
  movslq %edx,%rax
  cmpb   $0x58,0xe(%rsp,%rax,1)
  je     L289
L11:
  movslq %edx,%rax
  cmpb   $0x43,0xe(%rsp,%rax,1)
  jne    L200
  mov    $0x0,%eax
  jmp    L13
L289:
  sub    $0xa,%esi
  sub    $0x1,%edx
  jmp    L11
L132:
  add    $0x5a,%esi
  sub    $0x2,%edx
L130:
  movslq %edx,%rcx
  cmpb   $0x43,0xe(%rsp,%rcx,1)
  jne    L200
  cmp    $0x2,%eax
  jg     L200
L13:
  add    $0x1,%eax
  lea    -0x1(%rdx),%ecx
  movslq %ecx,%rdi
  cmpb   $0x58,0xe(%rsp,%rdi,1)
  je     L132
  add    $0x64,%esi
  mov    %ecx,%edx
  jmp    L130
L200:
  test   %edx,%edx
  jns    L206
  cmp    $0x100,%esi
  jg     L206
  lea    D20(%rip),%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  jmp    L220
L206:
  lea    D19(%rip),%rdi
  call   <puts@plt>
L220:
  mov    0x18(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L226
  mov    $0x0,%eax
  add    $0x20,%rsp
  pop    %rbx
  ret
L25:
  cmp    $0x4c,%al
  jne    L11
L156:
  add    $0x32,%esi
  sub    $0x1,%edx
  jmp    L141
L208:
  cmp    $0x56,%cl
  je     L219
  mov    $0x0,%esi
  jmp    L249
L226:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: parse_data
arguments: data_tag: D22
type_infered: string
name: parse_data
arguments: data_tag: D20
type_infered: string
name: parse_data
arguments: data_tag: D19
type_infered: string

tool: D22: %s

tool: D20: %d


tool: D19: Error: Input number too large, incorrect lined up characters or unknown symbol!

assistant: ```c
int main() {
  char c[10];
  int arabic = 0, iErr = 0, i;
  scanf("%s", c);
  i = strlen(c) - 1;
  while (c[i] == 'I' && iErr < 3) {
    arabic++;
    iErr++;
    i--;
  }
  if (c[i] == 'V') {
    arabic += 5;
    i--;
  }
  if (c[i] == 'I') {
    arabic--;
    i--;
  }
  iErr = 0;
  while (c[i] == 'X' && iErr < 3) {
    arabic += 10;
    iErr++;
    i--;
    if (c[i] == 'I') {
      arabic--;
      i--;
    }
  }
  if (c[i] == 'L') {
    arabic += 50;
    i--;
  }
  if (c[i] == 'X') {
    arabic -= 10;
    i--;
  }
  iErr = 0;
  while (c[i] == 'C' && iErr < 3) {
    arabic += 100;
    iErr++;
    i--;
    if (c[i] == 'X') {
      arabic -= 10;
      i--;
    }
  }
  if (i > -1 || arabic > 256) {
    printf("Error: Input number too large, incorrect lined up characters or unknown symbol!\n");
  } else {
    printf("%d\n", arabic);
  }
  return 0;
}
```