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

```asm
<Get_Fraction>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x20,%rsp
  mov    %rdi,-0x18(%rbp)
  movl   $0x0,-0xc(%rbp)
  mov    -0x18(%rbp),%rax
  lea    D71(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  mov    %rax,-0x8(%rbp)
  cmpq   $0x0,-0x8(%rbp)
  je     L78
  movl   $0x2,-0xc(%rbp)
  jmp    L80
L78:
  mov    -0x18(%rbp),%rax
  lea    D16(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  mov    %rax,-0x8(%rbp)
  cmpq   $0x0,-0x8(%rbp)
  je     L88
  movl   $0x3,-0xc(%rbp)
  jmp    L80
L88:
  mov    -0x18(%rbp),%rax
  lea    D18(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  mov    %rax,-0x8(%rbp)
  cmpq   $0x0,-0x8(%rbp)
  je     L94
  movl   $0x1,-0xc(%rbp)
  jmp    L80
L94:
  mov    -0x18(%rbp),%rax
  lea    D65(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  mov    %rax,-0x8(%rbp)
  cmpq   $0x0,-0x8(%rbp)
  je     L80
  movl   $0x2,-0xc(%rbp)
L80:
  cmpq   $0x0,-0x8(%rbp)
  je     L91
  mov    -0x8(%rbp),%rax
  lea    D45(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strcpy@plt>
L91:
  mov    -0x18(%rbp),%rax
  lea    D14(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L66
  movl   $0x2,-0xc(%rbp)
L66:
  mov    -0x18(%rbp),%rax
  lea    D19(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L52
  addl   $0x4,-0xc(%rbp)
L52:
  mov    -0x18(%rbp),%rax
  lea    D58(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L75
  addl   $0x8,-0xc(%rbp)
L75:
  mov    -0x18(%rbp),%rax
  lea    D36(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L41
  addl   $0xc,-0xc(%rbp)
L41:
  mov    -0x18(%rbp),%rax
  lea    D10(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L61
  addl   $0x10,-0xc(%rbp)
L61:
  mov    -0x18(%rbp),%rax
  lea    D21(%rip),%rdx
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <strstr@plt>
  test   %rax,%rax
  je     L8
  addl   $0x14,-0xc(%rbp)
L8:
  mov    -0xc(%rbp),%eax
  leave
  ret
```

tool_calls: name: parse_data
arguments: label: D71
data_type: string
name: parse_data
arguments: label: D16
data_type: string
name: parse_data
arguments: label: D18
data_type: string
name: parse_data
arguments: label: D65
data_type: string
name: parse_data
arguments: label: D45
data_type: string
name: parse_data
arguments: label: D14
data_type: string
name: parse_data
arguments: label: D19
data_type: string
name: parse_data
arguments: label: D58
data_type: string
name: parse_data
arguments: label: D36
data_type: string
name: parse_data
arguments: label: D10
data_type: string
name: parse_data
arguments: label: D21
data_type: string

tool: D71: 1/2

tool: D16: 3/4

tool: D18: 1/4

tool: D65: 2/4

tool: D45:    

tool: D14: half

tool: D19: one

tool: D58: two

tool: D36: three

tool: D10: four

tool: D21: five

assistant: ```c
int Get_Fraction(char *val) {
  int frac = 0;
  char *t;
  if ((t = strstr(val, "1/2")))
    frac = 2;
  else if ((t = strstr(val, "3/4")))
    frac = 3;
  else if ((t = strstr(val, "1/4")))
    frac = 1;
  else if ((t = strstr(val, "2/4")))
    frac = 2;
  if (t)
    strcpy(t, "   ");
  if (strstr(val, "half"))
    frac = 2;
  if (strstr(val, "one"))
    frac += 4;
  if (strstr(val, "two"))
    frac += 8;
  if (strstr(val, "three"))
    frac += 12;
  if (strstr(val, "four"))
    frac += 16;
  if (strstr(val, "five"))
    frac += 20;
  return (frac);
}
```