user: Translate the below assembly code into C programming language:

```asm
<main>:
  endbr64
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x2f0,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x2e8(%rsp)
  xor    %eax,%eax
  lea    0x10(%rsp),%rdi
  lea    D18(%rip),%rsi
  mov    $0x59,%ecx
  rep movsq %ds:(%rsi),%es:(%rdi)
  movzbl (%rsi),%eax
  mov    %al,(%rdi)
  movl   $0x0,(%rsp)
  movl   $0x0,0x4(%rsp)
  movl   $0x0,0x8(%rsp)
  movl   $0x0,0xc(%rsp)
  mov    $0x0,%r12d
  mov    $0x0,%ebx
  mov    $0x0,%ebp
  jmp    L61
L14:
  lea    0x1(%rbx),%ecx
  lea    0x3(%rbx),%eax
  cmp    $0x52,%dl
  cmove  %ecx,%eax
  cltd
  shr    $0x1e,%edx
  add    %edx,%eax
  and    $0x3,%eax
  sub    %edx,%eax
  mov    %eax,%edi
  mov    %eax,%ebx
  lea    0x1(%r12),%edx
  movslq %edx,%rax
  movzbl 0x10(%rsp,%rax,1),%eax
  lea    -0x30(%rax),%ecx
  cmp    $0x9,%cl
  ja     L74
  lea    0x2(%r12),%edx
  movslq %edx,%rdx
  mov    %ebp,%ecx
L19:
  lea    (%rcx,%rcx,4),%ecx
  movsbl %al,%eax
  lea    -0x30(%rax,%rcx,2),%ecx
  mov    %edx,%r12d
  movzbl 0x10(%rsp,%rdx,1),%eax
  add    $0x1,%rdx
  lea    -0x30(%rax),%esi
  cmp    $0x9,%sil
  jbe    L19
L55:
  movslq %edi,%rax
  add    %ecx,(%rsp,%rax,4)
L1:
  lea    0x10(%rsp),%rdi
  call   <strlen@plt>
  cmp    %r12d,%eax
  jle    L25
L61:
  movslq %r12d,%rax
  movzbl 0x10(%rsp,%rax,1),%edx
  cmp    $0x4c,%dl
  setne  %cl
  cmp    $0x52,%dl
  setne  %al
  test   %al,%cl
  je     L14
  test   %dl,%dl
  je     L14
  add    $0x1,%r12d
  jmp    L1
L74:
  mov    %edx,%r12d
  mov    %ebp,%ecx
  jmp    L55
L25:
  mov    (%rsp),%eax
  sub    0x8(%rsp),%eax
  mov    %eax,%esi
  neg    %esi
  cmovs  %eax,%esi
  mov    0x4(%rsp),%eax
  sub    0xc(%rsp),%eax
  mov    %eax,%edx
  neg    %edx
  cmovns %edx,%eax
  add    %eax,%esi
  lea    D1(%rip),%rdi
  call   <printf@plt>
  mov    0x2e8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L71
  add    $0x2f0,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  ret
L71:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: label: D18
data_type: string
name: extract_symbolic_data
arguments: label: D1
data_type: string

tool: D18: R3, L5, R2, L1, L2, R5, L2, R2, L2, L2, L1, R2, L2, R4, R4, R1, L2, L3, R3, L1, R2, L2, L4, R4, R5, L3, R3, L3, L3, R4, R5, L3, R3, L5, L1, L2, R2, L1, R3, R1, L1, R187, L1, R2, R47, L5, L1, L2, R4, R3, L3, R3, R4, R1, R3, L1, L4, L1, R2, L1, R4, R5, L1, R77, L5, L4, R3, L2, R4, R5, R5, L2, L2, R2, R5, L2, R194, R5, L2, R4, L5, L4, L2, R5, L3, L2, L5, R5, R2, L3, R3, R1, L4, R2, L1, R5, L1, R5, L1, L1, R3, L1, R5, R2, R5, R5, L4, L5, L5, L5, R3, L2, L5, L4, R3, R1, R1, R4, L2, L4, R5, R5, R4, L2, L2, R5, R5, L5, L2, R4, R4, L4, R1, L3, R1, L1, L1, L1, L4, R5, R4, L4, L4, R5, R3, L2, L2, R3, R1, R4, L3, R1, L4, R3, L3, L2, R2, R2, R2, L1, L4, R3, R2, R2, L3, R2, L3, L2, R4, L2, R3, L4, R5, R4, R1, R5, R3

tool: D1: %d

assistant: ```c
void main() {
  char plan[] = "R3, L5, R2, L1, L2, R5, L2, R2, L2, L2, L1, R2, L2, R4, R4, R1, L2, L3, R3, L1, R2, L2, L4, R4, R5, L3, R3, L3, L3, R4, R5, L3, R3, L5, L1, L2, R2, L1, R3, R1, L1, R187, L1, R2, R47, L5, L1, L2, R4, R3, L3, R3, R4, R1, R3, L1, L4, L1, R2, L1, R4, R5, L1, R77, L5, L4, R3, L2, R4, R5, R5, L2, L2, R2, R5, L2, R194, R5, L2, R4, L5, L4, L2, R5, L3, L2, L5, R5, R2, L3, R3, R1, L4, R2, L1, R5, L1, R5, L1, L1, R3, L1, R5, R2, R5, R5, L4, L5, L5, L5, R3, L2, L5, L4, R3, R1, R1, R4, L2, L4, R5, R5, R4, L2, L2, R5, R5, L5, L2, R4, R4, L4, R1, L3, R1, L1, L1, L1, L4, R5, R4, L4, L4, R5, R3, L2, L2, R3, R1, R4, L3, R1, L4, R3, L3, L2, R2, R2, R2, L1, L4, R3, R2, R2, L3, R2, L3, L2, R4, L2, R3, L4, R5, R4, R1, R5, R3";
  int azimuth = 0;
  int distances[4] = {0, 0, 0, 0};
  int i = 0;
  do {
    if (plan[i] != 'L' && plan[i] != 'R' && plan[i] != '\0') {
      i++;
      continue;
    }
    if (plan[i] == 'R') {
      azimuth += 1;
    } else {
      azimuth += 3;
    }
    azimuth = azimuth % 4;
    i++;
    int distance = 0;
    while (plan[i] >= '0' && plan[i] <= '9') {
      distance = distance * 10 + plan[i] - '0';
      i++;
    }
    distances[azimuth] += distance;
  } while (i < strlen(plan));
  printf("%d", abs(distances[0] - distances[2]) + abs(distances[1] - distances[3]));
}
```