In lieu of `else if`'s, how about:

```
if (str_len == 6) {
    return (strcmp(str, "count") == 0 || strcmp(str, "group") == 0);
}

if (str_len == 8) { ... }
```