Find the frequency of consecutive letters in sentence
Answers
Answered by
0
Explanation:
int main() { char string[100]; int c = 0, count[26] = {0}, x;
if (string[c] >= 'a' && string[c] <= 'z') { x = string[c] - 'a'; count[x]++; }
for (c = 0; c < 26; c++) printf("%c occurs %d times in the string.\ n", c + 'a', count[c]);
Similar questions