user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<main>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x48,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,0x38(%rsp)
  xor    %eax,%eax
  call   <fastRead_int@plt>
  test   %eax,%eax
  je     L174
  mov    %eax,%r13d
  lea    0x10(%rsp),%r14
  jmp    L212
L103:
  movsbl 0x10(%rsp),%edi
  call   <toupper@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  cmp    $0x1,%ebp
  jle    L29
  lea    0x11(%rsp),%rbx
  lea    -0x2(%rbp),%eax
  lea    0x12(%rsp,%rax,1),%rbp
L20:
  movsbl (%rbx),%edi
  call   <tolower@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  add    $0x1,%rbx
  cmp    %rbp,%rbx
  jne    L20
L29:
  mov    $0xa,%edi
  call   <putchar@plt>
  jmp    L136
L114:
  movsbl 0x10(%rsp),%edi
  call   <toupper@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  mov    $0x2e,%edi
  call   <putchar@plt>
  mov    $0x20,%edi
  call   <putchar@plt>
  cmpb   $0x20,0x11(%rsp)
  je     L68
  mov    $0x2,%eax
  lea    0xf(%rsp),%rdx
L171:
  mov    %eax,%ebx
  add    $0x1,%rax
  cmpb   $0x20,(%rdx,%rax,1)
  jne    L171
L68:
  lea    0x1(%rbx),%eax
  cltq
  movsbl 0x10(%rsp,%rax,1),%edi
  call   <toupper@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  lea    0x2(%rbx),%eax
  cltq
  movzbl 0x10(%rsp,%rax,1),%edi
  test   %dil,%dil
  je     L9
  movslq %ebx,%rbx
  add    %r14,%rbx
L52:
  movsbl %dil,%edi
  call   <tolower@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  add    $0x1,%rbx
  movzbl 0x2(%rbx),%edi
  test   %dil,%dil
  jne    L52
L9:
  mov    $0xa,%edi
  call   <putchar@plt>
  jmp    L136
L180:
  mov    $0x0,%ebx
  jmp    L112
L26:
  movsbl 0x2(%rbx),%edi
  call   <tolower@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  add    $0x1,%rbx
  cmp    %rbp,%rbx
  jne    L26
L42:
  mov    $0xa,%edi
  call   <putchar@plt>
L136:
  sub    $0x1,%r13d
  je     L174
L212:
  mov    %r14,%rdi
  call   <gets@plt>
  mov    %r14,%rdi
  call   <strlen@plt>
  mov    %eax,%ebp
  test   %eax,%eax
  jle    L103
  lea    0x10(%rsp),%rax
  lea    0x11(%rsp),%rsi
  mov    %rsi,0x8(%rsp)
  lea    -0x1(%rbp),%ecx
  add    %rsi,%rcx
  mov    $0x0,%ebx
L86:
  cmpb   $0x20,(%rax)
  sete   %dl
  movzbl %dl,%edx
  add    %edx,%ebx
  add    $0x1,%rax
  cmp    %rcx,%rax
  jne    L86
  test   %ebx,%ebx
  je     L103
  cmp    $0x1,%ebx
  je     L114
  movsbl 0x10(%rsp),%edi
  call   <toupper@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  mov    $0x2e,%edi
  call   <putchar@plt>
  mov    $0x20,%edi
  call   <putchar@plt>
  cmpb   $0x20,0x10(%rsp)
  je     L180
  mov    $0x1,%eax
  lea    0xf(%rsp),%rdx
L204:
  mov    %eax,%ebx
  add    $0x1,%rax
  cmpb   $0x20,(%rdx,%rax,1)
  jne    L204
L112:
  lea    0x1(%rbx),%r12d
  movslq %r12d,%r15
  movsbl 0x10(%rsp,%r15,1),%edi
  call   <toupper@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  mov    $0x2e,%edi
  call   <putchar@plt>
  mov    $0x20,%edi
  call   <putchar@plt>
  cmpb   $0x20,0x10(%rsp,%r15,1)
  je     L227
  add    $0x2,%ebx
  movslq %ebx,%rbx
  lea    0xf(%rsp),%rax
L93:
  mov    %ebx,%r12d
  add    $0x1,%rbx
  cmpb   $0x20,(%rax,%rbx,1)
  jne    L93
L227:
  lea    0x1(%r12),%eax
  cltq
  movsbl 0x10(%rsp,%rax,1),%edi
  call   <toupper@plt>
  movsbl %al,%edi
  call   <putchar@plt>
  lea    0x2(%r12),%eax
  cmp    %eax,%ebp
  jle    L42
  movslq %r12d,%rax
  lea    (%r14,%rax,1),%rbx
  sub    $0x3,%ebp
  sub    %r12d,%ebp
  add    0x8(%rsp),%rax
  add    %rax,%rbp
  jmp    L26
L174:
  mov    0x38(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L39
  mov    $0x0,%eax
  add    $0x48,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L39:
  call   <__stack_chk_fail@plt>
```

assistant: ```c
int main() {
  int T;
  T = fastRead_int();
  char str[32];
  int num, i, len;
  while (T--) {
    num = 0;
    i = 0;
    gets(str);
    len = strlen(str);
    while (i < len) {
      if (str[i] == ' ')
        num++;
      i++;
    }
    if (num == 0) {
      i = 0;
      putchar(toupper(str[0]));
      for (i = 1; i < len; i++) {
        putchar(tolower(str[i]));
      }
      putchar('\n');
    } else if (num == 1) {
      i = 0;
      putchar(toupper(str[0]));
      putchar('.');
      putchar(' ');
      i = 1;
      while (str[i] != ' ')
        i++;
      i++;
      putchar(toupper(str[i]));
      for (i = i + 1; str[i] != '\0'; i++) {
        putchar(tolower(str[i]));
      }
      putchar('\n');
    } else {
      i = 0;
      putchar(toupper(str[0]));
      putchar('.');
      putchar(' ');
      while (str[i] != ' ') {
        i++;
      }
      i++;
      putchar(toupper(str[i]));
      putchar('.');
      putchar(' ');
      while (str[i] != ' ')
        i++;
      i++;
      putchar(toupper(str[i]));
      for (i = i + 1; i < len; i++) {
        putchar(tolower(str[i]));
      }
      putchar('\n');
    }
  }
  return 0;
}
```