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

```asm
<main>:
  endbr64
  push   %r15
  lea    D19(%rip),%rdx
  push   %r14
  push   %r13
  lea    D8(%rip),%r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x8(%rsp)
  xor    %eax,%eax
  lea    0x4(%rsp),%rsi
  mov    %rsp,%rdi
  movl   $0xb,(%rsp)
  movl   $0x7,0x4(%rsp)
  call   <initgraph@plt>
  xor    %edi,%edi
  call   <setbkcolor@plt>
  xor    %eax,%eax
  call   <cleardevice@plt>
  xor    %eax,%eax
  call   <getmaxx@plt>
  mov    %eax,%ebx
  xor    %eax,%eax
  call   <getmaxy@plt>
  mov    %eax,%ebp
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  jne    L68
L95:
  mov    $0xe,%edi
  mov    $0x1f4,%r12d
  call   <setcolor@plt>
  mov    %r13,%rdx
  xor    %esi,%esi
  xor    %edi,%edi
  call   <outtextxy@plt>
  nopl   0x0(%rax,%rax,1)
L21:
  xor    %eax,%eax
  call   <rand@plt>
  movslq %eax,%rdx
  mov    %eax,%ecx
  imul   $0xffffffff88888889,%rdx,%rdx
  sar    $0x1f,%ecx
  shr    $0x20,%rdx
  add    %eax,%edx
  sar    $0x3,%edx
  sub    %ecx,%edx
  mov    %edx,%ecx
  shl    $0x4,%ecx
  sub    %edx,%ecx
  sub    %ecx,%eax
  lea    0x1(%rax),%edi
  call   <setcolor@plt>
  xor    %eax,%eax
  call   <rand@plt>
  mov    %eax,%r14d
  xor    %eax,%eax
  call   <rand@plt>
  cltd
  idiv   %ebp
  xor    %eax,%eax
  mov    %edx,%r15d
  call   <rand@plt>
  movslq %r14d,%rdx
  mov    %r14d,%ecx
  mov    %r15d,%esi
  imul   $0x51eb851f,%rdx,%rdx
  sar    $0x1f,%ecx
  sar    $0x25,%rdx
  sub    %ecx,%edx
  imul   $0x64,%edx,%edx
  sub    %edx,%r14d
  cltd
  idiv   %ebx
  mov    %edx,%edi
  mov    %r14d,%edx
  call   <circle@plt>
  sub    $0x1,%r12d
  jne    L21
  mov    $0x1,%edi
  call   <sleep@plt>
  xor    %eax,%eax
  call   <cleardevice@plt>
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  je     L95
L68:
  xor    %eax,%eax
  call   <check@plt>
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  jne    L55
L30:
  mov    $0xe,%edi
  mov    $0x1f4,%r12d
  call   <setcolor@plt>
  lea    D8(%rip),%rdx
  xor    %esi,%esi
  xor    %edi,%edi
  call   <outtextxy@plt>
  xchg   %ax,%ax
L125:
  xor    %eax,%eax
  call   <rand@plt>
  movslq %eax,%rdx
  mov    %eax,%ecx
  imul   $0xffffffff88888889,%rdx,%rdx
  sar    $0x1f,%ecx
  shr    $0x20,%rdx
  add    %eax,%edx
  sar    $0x3,%edx
  sub    %ecx,%edx
  mov    %edx,%ecx
  shl    $0x4,%ecx
  sub    %edx,%ecx
  sub    %ecx,%eax
  lea    0x1(%rax),%edi
  call   <setcolor@plt>
  xor    %eax,%eax
  call   <rand@plt>
  cltd
  idiv   %ebp
  xor    %eax,%eax
  mov    %edx,%r14d
  call   <rand@plt>
  cltd
  idiv   %ebx
  xor    %eax,%eax
  mov    %edx,%r15d
  call   <rand@plt>
  cltd
  idiv   %ebp
  xor    %eax,%eax
  mov    %edx,%r13d
  call   <rand@plt>
  mov    %r14d,%ecx
  mov    %r13d,%esi
  cltd
  idiv   %ebx
  mov    %edx,%edi
  mov    %r15d,%edx
  call   <line@plt>
  sub    $0x1,%r12d
  jne    L125
  mov    $0x1,%edi
  call   <sleep@plt>
  xor    %eax,%eax
  call   <cleardevice@plt>
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  je     L30
L55:
  xor    %eax,%eax
  lea    D25(%rip),%r13
  call   <check@plt>
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  jne    L25
L63:
  mov    $0xe,%edi
  mov    $0x3e8,%r12d
  call   <setcolor@plt>
  mov    %r13,%rdx
  xor    %esi,%esi
  xor    %edi,%edi
  call   <outtextxy@plt>
  mov    $0x7dc,%edi
  call   <srand@plt>
  jmp    L38
L37:
  mov    $0x1,%edi
  call   <delay@plt>
  sub    $0x1,%r12d
  je     L138
L38:
  xor    %eax,%eax
  call   <rand@plt>
  mov    %eax,%r14d
  xor    %eax,%eax
  call   <rand@plt>
  cltd
  idiv   %ebp
  xor    %eax,%eax
  mov    %edx,%r15d
  call   <rand@plt>
  movslq %r14d,%rdx
  mov    %r14d,%ecx
  mov    %r15d,%esi
  imul   $0xffffffff88888889,%rdx,%rdx
  sar    $0x1f,%ecx
  shr    $0x20,%rdx
  add    %r14d,%edx
  sar    $0x3,%edx
  sub    %ecx,%edx
  mov    %edx,%ecx
  shl    $0x4,%ecx
  sub    %edx,%ecx
  cltd
  idiv   %ebx
  sub    %ecx,%r14d
  add    $0x1,%r14d
  mov    %edx,%edi
  mov    %r14d,%edx
  call   <putpixel@plt>
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  je     L37
L138:
  mov    $0x1,%edi
  mov    $0x3e8,%r12d
  call   <sleep@plt>
  mov    $0x7dc,%edi
  call   <srand@plt>
  jmp    L119
L149:
  mov    $0x1,%edi
  call   <delay@plt>
  sub    $0x1,%r12d
  je     L67
L119:
  xor    %eax,%eax
  call   <rand@plt>
  xor    %eax,%eax
  call   <rand@plt>
  cltd
  idiv   %ebp
  xor    %eax,%eax
  mov    %edx,%r14d
  call   <rand@plt>
  mov    %r14d,%esi
  cltd
  idiv   %ebx
  mov    %edx,%edi
  xor    %edx,%edx
  call   <putpixel@plt>
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  je     L149
L67:
  mov    $0x1,%edi
  call   <sleep@plt>
  xor    %eax,%eax
  call   <cleardevice@plt>
  xor    %eax,%eax
  call   <kbhit@plt>
  test   %rax,%rax
  je     L63
L25:
  xor    %eax,%eax
  call   <closegraph@plt>
  mov    0x8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L127
  add    $0x18,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L127:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D19
type: string
name: extract_symbolic_data
arguments: data_label: D8
type: string
name: extract_symbolic_data
arguments: data_label: D25
type: string

tool: 

tool: D8: Press a key to continue

tool: D25: Press a key to exit

assistant: ```c
int main(void) {
  int i, col, gd, gm, x, y;
  gd = 11;
  gm = 7;
  initgraph(&gd, &gm, "");
  setbkcolor(0);
  cleardevice();
  x = getmaxx();
  y = getmaxy();
  while (!kbhit()) {
    setcolor(14);
    outtextxy(0, 0, "Press a key to continue");
    for (i = 0; i < 500; i++) {
      setcolor(1 + (rand() % (15)));
      circle((rand() % (x)), (rand() % (y)), (rand() % (100)));
    }
    sleep(1);
    cleardevice();
  }
  check();
  while (!kbhit()) {
    setcolor(14);
    outtextxy(0, 0, "Press a key to continue");
    for (i = 0; i < 500; i++) {
      setcolor(1 + (rand() % (15)));
      line((rand() % (x)), (rand() % (y)), (rand() % (x)), (rand() % (y)));
    }
    sleep(1);
    cleardevice();
  }
  check();
  while (!kbhit()) {
    setcolor(14);
    outtextxy(0, 0, "Press a key to exit");
    srand(2012);
    for (i = 0; i < 1000; i++) {
      col = 1 + (rand() % (15));
      putpixel((rand() % (x)), (rand() % (y)), col);
      if (kbhit())
        break;
      delay(1);
    }
    sleep(1);
    srand(2012);
    for (i = 0; i < 1000; i++) {
      col = 1 + (rand() % (15));
      putpixel((rand() % (x)), (rand() % (y)), 0);
      if (kbhit())
        break;
      delay(1);
    }
    sleep(1);
    cleardevice();
  }
  closegraph();
  return 0;
}
```