Answered step by step
Verified Expert Solution
Question
1 Approved Answer
read_line function is as follows: int read_line(FILE *fp, char *str, int n) { int ch, i =0; while ((ch = fgetc(fp)) != ' ') {
read_line function is as follows:
int read_line(FILE *fp, char *str, int n) { int ch, i =0; while ((ch = fgetc(fp)) != ' ') { // printf("%c", ch); if (i
return i; }
Project 7 Extra credit (40 points) Write a program that reads in a line of text, and display the acronyms in the sentences. The input are assumed be line of English words separated by white spaces comma, period, or exclamation point. The output contains the list of acronyms in the nput. lhe list of acronyms you will search for TBH, BRB, LOL, IDK, TTYL, IRL, TIA, AFK, CYA, FYI, OMG For example Input: TBH, 1DK ?f my hashtag will end up trending or if anyone will even like it. It will only be viral if people can relate to it IRL Output: TBH IDK IRL 1) 2) Assume input is no longer than 1000 characters. Assume the input contains no 3) You may find string library functions such as strtok, strcmp, and 4) To read a line of text, use the readline function in the lecture notes Name your program words.c. more than 500 words. Assume each word is no more than 50 characters. strcpy helpfulStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started