Question: Is it possible to switch Network Link Conditioner profiles from MacOS command line or by using script, and generally is it possible to automate NLC, if so how?

Thank you in advance.

Answer: 
you seem to only check the first letter of each word, then move on to the next word. clearly you need 2 loops working there.

or something like:

```
while (c<N) {
    if(( *words[c]>='a' && *words[c]<='z') || (*words[c]>='A' &&  *words[c]  <='Z')) {                    

        freq[*words[c]-'a']++;
    }
    words[c]++;
    if(*words[c] == '\0')
        c++;
}

```

but i think you will end up with an array of ends of strings, it dos not seem to matter, but it is still strange.
Start by distinguishing between upper and lower case. This may not be the complete solution, but it's a start.

```
    if (*words[c]>='a' && *words[c]<='z'){                       
        freq[*words[c]-'a']++;
        words[c]++;
    }
    else if (*words[c]>='A' &&  *words[c]  <='Z'){                       
        freq[*words[c]-'A']++;
        words[c]++;
    }

```