Question: Ques write a program in c language that meets the following requirements. Requirements . Write a program that calculates the frequency of letter occurrences in
Ques write a program in c language that meets the following requirements.

Requirements . Write a program that calculates the frequency of letter occurrences in text. . Read ASCIl text from standard input On reaching EOF, print to stdout the normalized frequency of occurrence for each letter a-z that appeared in the input, one per line, in alphabetical order using the format produced by printf( "%c %.4f ", letter, freq ); . Letters that occur zero times should not appear in the output Characters other than lower and upper case letters should be ignored Lower and upper case instances count as the same letter, e.g. 'a' and 'A' are both reported for the letter 'a' on the output. The frequencies reported should sum to approximately 1 (with a little slack for accumulation of printf rounding errors) Example runs Assume you have named yourexecutable lfreq. The first two example runs show the user entering the text manually in the terminal. The third and fourth runs have text piped in from a file (and the middle of the alphabet is omitted from the output for brevity). A text file happy_prince.txt containing a classic story in English is provided for testing ./lfreq aaab a 0.7500 b 0.2500 ./lfreq q 1.0000 ./1freq
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
