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

```asm
<convert_to_decimal>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0x38,%rsp
  mov    %rdi,-0x38(%rbp)
  mov    %esi,-0x3c(%rbp)
  movq   $0x0,-0x18(%rbp)
  movl   $0x0,-0x24(%rbp)
  movl   $0x0,-0x20(%rbp)
  mov    -0x38(%rbp),%rax
  mov    %rax,%rdi
  call   <strlen@plt>
  mov    %eax,-0x1c(%rbp)
  jmp    L41
L72:
  cmpl   $0x10,-0x3c(%rbp)
  jne    L54
  mov    -0x1c(%rbp),%eax
  sub    $0x1,%eax
  sub    -0x20(%rbp),%eax
  movslq %eax,%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  sub    $0x41,%eax
  cmp    $0x5,%eax
  ja     L33
  mov    %eax,%eax
  lea    0x0(,%rax,4),%rdx
  lea    D10(%rip),%rax
  mov    (%rdx,%rax,1),%eax
  cltq
  lea    D10(%rip),%rdx
  add    %rdx,%rax
  notrack jmp *%rax
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%edx
  mov    %edx,%eax
  shl    $0x2,%eax
  add    %edx,%eax
  add    %eax,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x20(%rbp)
  addl   $0x1,-0x24(%rbp)
  jmp    L41
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%edx
  mov    %edx,%eax
  shl    $0x2,%eax
  add    %edx,%eax
  add    %eax,%eax
  add    %edx,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x20(%rbp)
  addl   $0x1,-0x24(%rbp)
  jmp    L41
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%edx
  mov    %edx,%eax
  add    %eax,%eax
  add    %edx,%eax
  shl    $0x2,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x20(%rbp)
  addl   $0x1,-0x24(%rbp)
  jmp    L41
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%edx
  mov    %edx,%eax
  add    %eax,%eax
  add    %edx,%eax
  shl    $0x2,%eax
  add    %edx,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x20(%rbp)
  addl   $0x1,-0x24(%rbp)
  jmp    L41
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%eax
  imul   $0xe,%eax,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x20(%rbp)
  addl   $0x1,-0x24(%rbp)
  jmp    L41
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%edx
  mov    %edx,%eax
  shl    $0x4,%eax
  sub    %edx,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x20(%rbp)
  addl   $0x1,-0x24(%rbp)
  jmp    L41
L33:
  mov    -0x1c(%rbp),%eax
  lea    -0x1(%rax),%ecx
  mov    -0x20(%rbp),%eax
  lea    0x1(%rax),%edx
  mov    %edx,-0x20(%rbp)
  sub    %eax,%ecx
  mov    %ecx,%edx
  movslq %edx,%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  lea    -0x30(%rax),%ebx
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%eax
  imul   %ebx,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x24(%rbp)
  jmp    L41
L54:
  mov    -0x1c(%rbp),%eax
  lea    -0x1(%rax),%ecx
  mov    -0x20(%rbp),%eax
  lea    0x1(%rax),%edx
  mov    %edx,-0x20(%rbp)
  sub    %eax,%ecx
  mov    %ecx,%edx
  movslq %edx,%rdx
  mov    -0x38(%rbp),%rax
  add    %rdx,%rax
  movzbl (%rax),%eax
  movsbl %al,%eax
  lea    -0x30(%rax),%ebx
  mov    -0x24(%rbp),%edx
  mov    -0x3c(%rbp),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <powerfunc@plt>
  movsbl %al,%eax
  imul   %ebx,%eax
  cltq
  add    %rax,-0x18(%rbp)
  addl   $0x1,-0x24(%rbp)
L41:
  mov    -0x1c(%rbp),%eax
  sub    $0x1,%eax
  sub    -0x20(%rbp),%eax
  test   %eax,%eax
  jns    L72
  mov    -0x18(%rbp),%rax
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

assistant: ```c
long int convert_to_decimal(char *array, int base) {
  long int decimal_numb = 0;
  int power = 0;
  int counter = 0;
  int length;
  length = strlen(array);
  while (length - 1 - counter >= 0) {
    if (base == 16) {
      switch (array[length - 1 - counter]) {
      case 'A': {
        decimal_numb = decimal_numb + 10 * powerfunc(base, power);
        counter++;
        power++;
        break;
      }
      case 'B': {
        decimal_numb = decimal_numb + 11 * powerfunc(base, power);
        counter++;
        power++;
        break;
      }
      case 'C': {
        decimal_numb = decimal_numb + 12 * powerfunc(base, power);
        counter++;
        power++;
        break;
      }
      case 'D': {
        decimal_numb = decimal_numb + 13 * powerfunc(base, power);
        counter++;
        power++;
        break;
      }
      case 'E': {
        decimal_numb = decimal_numb + 14 * powerfunc(base, power);
        counter++;
        power++;
        break;
      }
      case 'F': {
        decimal_numb = decimal_numb + 15 * powerfunc(base, power);
        counter++;
        power++;
        break;
      }
      default: {
        decimal_numb = decimal_numb + (array[length - 1 - counter++] - '0') * powerfunc(base, power);
        power++;
      }
      }
    } else {
      decimal_numb = decimal_numb + (array[length - 1 - counter++] - '0') * powerfunc(base, power);
      power++;
    }
  }
  return decimal_numb;
}
```