user: Please show me the C implementation that matches the assembly code listed below:

```asm
<main>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  add    $0xffffffffffffff80,%rsp
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
L64:
  lea    D45(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    D67(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    -0x78(%rbp),%rax
  mov    %rax,%rsi
  lea    D48(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  mov    $0x0,%eax
  call   <getchar@plt>
  mov    -0x78(%rbp),%eax
  cmp    $0x3,%eax
  je     L86
  cmp    $0x3,%eax
  jg     L21
  cmp    $0x1,%eax
  je     L33
  cmp    $0x2,%eax
  je     L43
  jmp    L21
L33:
  lea    D1(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    -0x70(%rbp),%rax
  mov    %rax,%rdi
  call   <gets@plt>
  jmp    L39
L43:
  lea    D63(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    -0x7c(%rbp),%rax
  mov    %rax,%rsi
  lea    D48(%rip),%rax
  mov    %rax,%rdi
  call   <scanf@plt>
  movl   $0x0,-0x74(%rbp)
  jmp    L95
L3:
  mov    -0x74(%rbp),%eax
  cltq
  movzbl -0x70(%rbp,%rax,1),%eax
  mov    %eax,%edx
  mov    -0x7c(%rbp),%eax
  add    %edx,%eax
  mov    %eax,%edx
  mov    -0x74(%rbp),%eax
  cltq
  mov    %dl,-0x50(%rbp,%rax,1)
  addl   $0x1,-0x74(%rbp)
L95:
  mov    -0x74(%rbp),%eax
  cltq
  movzbl -0x70(%rbp,%rax,1),%eax
  test   %al,%al
  jne    L3
  lea    D49(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    -0x50(%rbp),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  jmp    L39
L86:
  movl   $0x0,-0x74(%rbp)
  jmp    L53
L18:
  mov    -0x74(%rbp),%eax
  cltq
  movzbl -0x50(%rbp,%rax,1),%eax
  mov    %eax,%edx
  mov    -0x7c(%rbp),%eax
  mov    %eax,%ecx
  mov    %edx,%eax
  sub    %ecx,%eax
  mov    %eax,%edx
  mov    -0x74(%rbp),%eax
  cltq
  mov    %dl,-0x30(%rbp,%rax,1)
  addl   $0x1,-0x74(%rbp)
L53:
  mov    -0x74(%rbp),%eax
  cltq
  movzbl -0x70(%rbp,%rax,1),%eax
  test   %al,%al
  jne    L18
  mov    -0x74(%rbp),%eax
  cltq
  movb   $0x0,-0x30(%rbp,%rax,1)
  lea    D55(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  lea    -0x30(%rbp),%rax
  mov    %rax,%rdi
  call   <puts@plt>
  jmp    L39
L21:
  mov    $0x0,%edi
  call   <exit@plt>
L39:
  jmp    L64
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D45
datatype: string
name: extract_symbolic_data
arguments: data_label: D67
datatype: string
name: extract_symbolic_data
arguments: data_label: D48
datatype: string
name: extract_symbolic_data
arguments: data_label: D1
datatype: string
name: extract_symbolic_data
arguments: data_label: D63
datatype: string
name: extract_symbolic_data
arguments: data_label: D49
datatype: string
name: extract_symbolic_data
arguments: data_label: D55
datatype: string

tool: D45: 
MENU
=====
1.Input
2.Encode
3.Decode
4.Exit

tool: D67: 
Enter your choice


tool: D48: %d

tool: D1: 
Enter a str


tool: D63: 
Enter a key


tool: D49: 
Encoded String :


tool: D55: 
Decoded String :


assistant: ```c
int main(void) {
  char Str[30], encStr[30], decStr[30];
  int i, iKey, iChoice;
  while (1) {
    printf("\nMENU\n=====\n1.Input\n2.Encode\n3.Decode\n4.Exit");
    printf("\nEnter your choice\n");
    scanf("%d", &iChoice);
    getchar();
    switch (iChoice) {
    case 1:
      printf("\nEnter a str\n");
      gets(Str);
      break;
    case 2:
      printf("\nEnter a key\n");
      scanf("%d", &iKey);
      for (i = 0; Str[i] != '\0'; i++) {
        encStr[i] = Str[i] + iKey;
      }
      printf("\nEncoded String :\n");
      puts(encStr);
      break;
    case 3:
      for (i = 0; Str[i] != '\0'; i++) {
        decStr[i] = encStr[i] - iKey;
      }
      decStr[i] = '\0';
      printf("\nDecoded String :\n");
      puts(decStr);
      break;
    default:
      exit(0);
    }
  }
  return 0;
}
```