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

```asm
<main>:
  endbr64
  sub    $0x18,%rsp
  lea    D14(%rip),%rdi
  mov    %fs:0x28,%rax
  mov    %rax,0x8(%rsp)
  xor    %eax,%eax
  call   <printf@plt>
  lea    0x4(%rsp),%rsi
  lea    D127(%rip),%rdi
  xor    %eax,%eax
  call   <scanf@plt>
  lea    D45(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  lea    0x3(%rsp),%rsi
  lea    D115(%rip),%rdi
  xor    %eax,%eax
  call   <scanf@plt>
  movzbl 0x3(%rsp),%eax
  cmp    $0x75,%al
  je     L58
  cmp    $0x67,%al
  je     L63
  cmp    $0x65,%al
  je     L25
  cmp    $0x6b,%al
  je     L51
  lea    D100(%rip),%rdi
  call   <puts@plt>
L75:
  mov    0x8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L77
  xor    %eax,%eax
  add    $0x18,%rsp
  ret
L51:
  lea    D103(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  movss  D49(%rip),%xmm1
L86:
  movss  0x4(%rsp),%xmm0
  lea    D65(%rip),%rdi
  mov    $0x1,%eax
  divss  %xmm1,%xmm0
  cvtss2sd %xmm0,%xmm0
  call   <printf@plt>
  jmp    L75
L58:
  lea    D53(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  movss  D15(%rip),%xmm1
  jmp    L86
L63:
  lea    D125(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  movss  D70(%rip),%xmm1
  jmp    L86
L25:
  lea    D101(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  movss  D77(%rip),%xmm1
  jmp    L86
L77:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: disassemble_data
arguments: data_tag: D14
type_guessed: string
name: disassemble_data
arguments: data_tag: D127
type_guessed: string
name: disassemble_data
arguments: data_tag: D45
type_guessed: string
name: disassemble_data
arguments: data_tag: D115
type_guessed: string
name: disassemble_data
arguments: data_tag: D100
type_guessed: string
name: disassemble_data
arguments: data_tag: D103
type_guessed: string
name: disassemble_data
arguments: data_tag: D49
type_guessed: f32
name: disassemble_data
arguments: data_tag: D65
type_guessed: string
name: disassemble_data
arguments: data_tag: D53
type_guessed: string
name: disassemble_data
arguments: data_tag: D15
type_guessed: f32
name: disassemble_data
arguments: data_tag: D125
type_guessed: string
name: disassemble_data
arguments: data_tag: D70
type_guessed: f32
name: disassemble_data
arguments: data_tag: D101
type_guessed: string
name: disassemble_data
arguments: data_tag: D77
type_guessed: f32

tool: D14:  How many yen?  

tool: D127: %f

tool: D45:  Which currency?  

tool: D115: %*c %c

tool: D100:  Unknown.

tool: D103: KRW = 

tool: D49: 0.08

tool: D65: %.2f


tool: D53: USD = 

tool: D15: 90.66

tool: D125: GBP = 

tool: D70: 149

tool: D101: EUR = 

tool: D77: 135.43

assistant: ```c
int main() {
  char c;
  float yen;
  float answer;
  float cy;
  printf(" How many yen?  ");
  scanf("%f", &yen);
  printf(" Which currency?  ");
  scanf("%*c %c", &c);
  if (c == 'u') {
    cy = 90.66;
    printf("USD = ");
  } else if (c == 'g') {
    cy = 149.00;
    printf("GBP = ");
  } else if (c == 'e') {
    cy = 135.43;
    printf("EUR = ");
  } else if (c == 'k') {
    cy = 0.08;
    printf("KRW = ");
  } else {
    printf(" Unknown.\n");
    return 0;
  }
  answer = (yen / cy);
  printf("%.2f\n", answer);
  return 0;
}
```