user: What is the c source code of the assembly code below?

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movl   $0x1,-0xc(%rbp)
  lea    D61(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  lea    -0x14(%rbp),%rax
  mov    %rax,%rsi
  lea    D17(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  mov    -0x14(%rbp),%eax
  test   %eax,%eax
  jns    L98
  lea    D88(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  jmp    L164
L98:
  mov    -0x14(%rbp),%eax
  cmp    $0x3,%eax
  jg     L2
  lea    D80(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  mov    $0x0,%eax
  jmp    L164
L2:
  movl   $0x2,-0x10(%rbp)
  jmp    L57
L184:
  mov    -0x14(%rbp),%eax
  cltd
  idivl  -0x10(%rbp)
  mov    %edx,%eax
  test   %eax,%eax
  jne    L44
  mov    -0x14(%rbp),%eax
  mov    -0x10(%rbp),%edx
  mov    %eax,%esi
  lea    D23(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movl   $0x0,-0xc(%rbp)
  jmp    L174
L44:
  addl   $0x1,-0x10(%rbp)
L57:
  mov    -0x14(%rbp),%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  cmp    %eax,-0x10(%rbp)
  jle    L184
L174:
  cmpl   $0x0,-0xc(%rbp)
  je     L101
  mov    -0x14(%rbp),%eax
  mov    %eax,%esi
  lea    D71(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
L101:
  movl   $0x1,-0xc(%rbp)
  movl   $0x2,-0x10(%rbp)
  jmp    L29
L43:
  mov    -0x14(%rbp),%eax
  cltd
  idivl  -0x10(%rbp)
  mov    %edx,%eax
  test   %eax,%eax
  jne    L10
  mov    -0x14(%rbp),%eax
  mov    -0x10(%rbp),%edx
  mov    %eax,%esi
  lea    D23(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movl   $0x0,-0xc(%rbp)
  jmp    L181
L10:
  addl   $0x1,-0x10(%rbp)
L29:
  mov    -0x14(%rbp),%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  cmp    %eax,-0x10(%rbp)
  jle    L43
L181:
  cmpl   $0x0,-0xc(%rbp)
  je     L155
  mov    -0x14(%rbp),%eax
  mov    %eax,%esi
  lea    D71(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
L155:
  movl   $0x1,-0xc(%rbp)
  movl   $0x2,-0x10(%rbp)
L55:
  mov    -0x14(%rbp),%eax
  cltd
  idivl  -0x10(%rbp)
  mov    %edx,%eax
  test   %eax,%eax
  jne    L147
  mov    -0x14(%rbp),%eax
  mov    -0x10(%rbp),%edx
  mov    %eax,%esi
  lea    D23(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
  movl   $0x0,-0xc(%rbp)
  jmp    L45
L147:
  addl   $0x1,-0x10(%rbp)
  mov    -0x14(%rbp),%eax
  mov    %eax,%edi
  call   <sqrt@plt>
  cmp    %eax,-0x10(%rbp)
  jle    L55
L45:
  cmpl   $0x0,-0xc(%rbp)
  je     L23
  mov    -0x14(%rbp),%eax
  mov    %eax,%esi
  lea    D71(%rip),%rax
  mov    %rax,%rdi
  mov    $0x0,%eax
  call   <printf@plt>
L23:
  mov    $0x0,%eax
L164:
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L182
  call   <__stack_chk_fail@plt>
L182:
  leave
  ret
```

tool_calls: name: disassemble_data
arguments: tag: D61
data_type: string
name: disassemble_data
arguments: tag: D17
data_type: string
name: disassemble_data
arguments: tag: D88
data_type: string
name: disassemble_data
arguments: tag: D80
data_type: string
name: disassemble_data
arguments: tag: D23
data_type: string
name: disassemble_data
arguments: tag: D71
data_type: string

tool: D61: Enter the number: 

tool: D17: %d

tool: D88: Number must be positive

tool: D80: Number is prime

tool: D23: Number %d is not prime, denominator is %d



tool: D71: Number %d is prime



assistant: ```c
int main() {
  int number, denominator, is_prime = 1;
  printf("Enter the number: ");
  scanf("%d", &number);
  if (number < 0) {
    printf("Number must be positive");
    return 0;
  }
  if (number <= 3) {
    printf("Number is prime");
    return 0;
  }
  for (denominator = 2; denominator <= (int)sqrt(number); denominator++) {
    if ((number % denominator) == 0) {
      printf("Number %d is not prime, denominator is %d\n\n", number, denominator);
      is_prime = 0;
      break;
    }
  }
  if (is_prime) {
    printf("Number %d is prime\n\n", number);
  }
  is_prime = 1;
  denominator = 2;
  while (denominator <= (int)sqrt(number)) {
    if ((number % denominator) == 0) {
      printf("Number %d is not prime, denominator is %d\n\n", number, denominator);
      is_prime = 0;
      break;
    }
    denominator++;
  }
  if (is_prime) {
    printf("Number %d is prime\n\n", number);
  }
  is_prime = 1;
  denominator = 2;
  do {
    if ((number % denominator) == 0) {
      printf("Number %d is not prime, denominator is %d\n\n", number, denominator);
      is_prime = 0;
      break;
    }
    denominator++;
  } while (denominator <= (int)sqrt(number));
  if (is_prime) {
    printf("Number %d is prime\n\n", number);
  }
  return 0;
}
```