user: What would the C source look like for the assembly code provided here?

```asm
<main>:
  endbr64
  push   %r15
  mov    $0x32,%ecx
  lea    D19(%rip),%r15
  push   %r14
  lea    D9(%rip),%r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x518,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x508(%rsp)
  xor    %eax,%eax
  lea    0x50(%rsp),%rdi
  mov    %rdi,0x38(%rsp)
  rep stos %rax,%es:(%rdi)
  lea    0x1e0(%rsp),%rdi
  mov    $0x32,%ecx
  mov    %rdi,0x8(%rsp)
  rep stos %rax,%es:(%rdi)
  lea    0x370(%rsp),%rdi
  mov    $0x32,%ecx
  mov    %rdi,(%rsp)
  rep stos %rax,%es:(%rdi)
  lea    0x4c(%rsp),%rax
  mov    %rax,0x30(%rsp)
L134:
  mov    0x30(%rsp),%rsi
  lea    D38(%rip),%rdi
  call   <scanf@plt>
  test   %rax,%rax
  jle    L191
  mov    0x4c(%rsp),%eax
  test   %eax,%eax
  jle    L134
  lea    0x78(%rsp),%rax
  movl   $0x1,0x1c(%rsp)
  lea    0x414(%rsp),%rbx
  mov    %rax,0x28(%rsp)
  lea    0x1e4(%rsp),%rax
  lea    D46(%rip),%r12
  mov    %rax,0x20(%rsp)
  lea    0x374(%rsp),%rax
  mov    %rax,0x10(%rsp)
L1:
  mov    0x38(%rsp),%rbp
  mov    0x28(%rsp),%r13
L27:
  mov    %rbp,%rsi
  lea    D38(%rip),%rdi
  add    $0x4,%rbp
  call   <scanf@plt>
  cmp    %r13,%rbp
  jne    L27
  mov    (%rsp),%rdi
  mov    $0x190,%edx
  xor    %esi,%esi
  call   <memset@plt>
  movl   $0x32,0x18(%rsp)
  movl   $0x1,0x3c0(%rsp)
  nopl   (%rax)
L30:
  mov    0x10(%rsp),%r13
  lea    D40(%rip),%rbp
  jmp    L139
  xchg   %ax,%ax
L148:
  cmp    $0x1,%eax
  jne    L157
  mov    %rbp,%rdi
  call   <printf@plt>
L157:
  add    $0x4,%r13
  cmp    %rbx,%r13
  je     L183
L139:
  mov    0x0(%r13),%eax
  cmp    $0x2,%eax
  je     L192
  jg     L213
  test   %eax,%eax
  jne    L148
  mov    %r12,%rdi
  add    $0x4,%r13
  call   <printf@plt>
  cmp    %rbx,%r13
  jne    L139
  xchg   %ax,%ax
L183:
  mov    $0xa,%edi
  call   <putchar@plt>
  mov    0x8(%rsp),%rbp
  mov    (%rsp),%rsi
  mov    $0x190,%edx
  mov    %rbp,%rdi
  call   <memcpy@plt>
  mov    0x1e8(%rsp),%r8d
  mov    $0x4,%eax
  mov    %rbp,%r11
  mov    0x1e4(%rsp),%edi
  mov    %r8d,%r9d
  mov    %edi,%esi
L15:
  lea    (%r9,%rsi,1),%edx
  mov    -0x4(%r11,%rax,4),%esi
  mov    %eax,%r10d
  lea    (%rsi,%r9,1),%ecx
  mov    (%r11,%rax,4),%r9d
  add    %esi,%edx
  movslq %edx,%rdx
  add    %r9d,%ecx
  movd   0x50(%rsp,%rdx,4),%xmm0
  movslq %ecx,%rcx
  mov    0x50(%rsp,%rcx,4),%ecx
  movd   %ecx,%xmm1
  mov    (%rsp),%rcx
  punpckldq %xmm1,%xmm0
  movq   %xmm0,-0x8(%rcx,%rax,4)
  add    $0x2,%rax
  cmp    $0x2a,%rax
  jne    L15
  mov    0x8(%rsp),%rax
  movslq %r10d,%rsi
  shl    $0x2,%rsi
  lea    (%rax,%rsi,1),%rdx
  lea    (%rcx,%rsi,1),%rcx
  add    0x20(%rsp),%rsi
  nopw   0x0(%rax,%rax,1)
L42:
  mov    (%rdx),%eax
  add    -0x4(%rdx),%eax
  add    $0x4,%rdx
  add    $0x4,%rcx
  add    (%rdx),%eax
  cltq
  mov    0x50(%rsp,%rax,4),%eax
  mov    %eax,-0x4(%rcx)
  cmp    %rsi,%rdx
  jne    L42
  add    %r8d,%edi
  subl   $0x1,0x18(%rsp)
  movslq %edi,%rdi
  mov    0x50(%rsp,%rdi,4),%eax
  mov    %eax,0x374(%rsp)
  jne    L30
  mov    0x4c(%rsp),%eax
  cmp    0x1c(%rsp),%eax
  jg     L143
  addl   $0x1,0x1c(%rsp)
  mov    0x1c(%rsp),%edi
  cmp    %edi,%eax
  jge    L1
  jmp    L134
  nopl   0x0(%rax)
L213:
  cmp    $0x3,%eax
  jne    L157
  mov    %r15,%rdi
  call   <printf@plt>
  jmp    L157
  cs nopw 0x0(%rax,%rax,1)
L192:
  mov    %r14,%rdi
  call   <printf@plt>
  jmp    L157
L143:
  mov    $0xa,%edi
  call   <putchar@plt>
  addl   $0x1,0x1c(%rsp)
  mov    0x1c(%rsp),%eax
  cmp    0x4c(%rsp),%eax
  jle    L1
  jmp    L134
L191:
  mov    0x508(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L31
  add    $0x518,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L31:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: unpack_data
arguments: tag: D19
type_infered: string
name: unpack_data
arguments: tag: D9
type_infered: string
name: unpack_data
arguments: tag: D38
type_infered: string
name: unpack_data
arguments: tag: D46
type_infered: string
name: unpack_data
arguments: tag: D40
type_infered: string

tool: D19: W

tool: D9: x

tool: D38: %d

tool: D46:  

tool: D40: .

assistant: ```c
main() {
  int n, d[100] = {0}, y[100] = {0}, t[100] = {0}, i, j, k, l, m;
  while (scanf("%d", &n) > 0) {
    for (m = 1; m <= n; m++) {
      for (i = 0; i < 10; i++)
        scanf("%d", &d[i]);
      memset(t, 0, sizeof(t));
      t[20] = 1;
      for (l = 0; l < 50; l++) {
        for (j = 1; j <= 40; j++)
          switch (t[j]) {
          case 0:
            printf(" ");
            break;
          case 1:
            printf(".");
            break;
          case 2:
            printf("x");
            break;
          case 3:
            printf("W");
            break;
          default:
            break;
          }
        putchar('\n');
        memcpy(y, t, sizeof(y));
        for (j = 2; j <= 40; j++)
          t[j] = d[y[j] + y[j - 1] + y[j + 1]];
        t[1] = d[y[1] + y[2]];
      }
      if (m < n)
        putchar('\n');
    }
  }
  return 0;
}
```