Answered step by step
Verified Expert Solution
Question
1 Approved Answer
1) A concordance is a list of words appearing in a body of text. The list of words includes only true words, consisting entirely of
1) A concordance is a list of words appearing in a body of text. The list of words includes only "true" words, consisting entirely of alphabetic characters, after all punctuation and whitespace characters have been discarded. Write a C99 function, with the prototype char **concordance (char *filename, int *nwords); to build a concordance from a named text file. The first parameter, filename, provides the name of the text file containing the words. You may assume that the text file contains only alphabetic, punctuation, and whitespace characters The second parameter, nwords, provides a pointer to an integer. On successful return from the function, the integer pointed to by nwords will contain the number of distinct words found in the file. On successful return, concordance will return a vector of strings, containing the distinct words found in the text file If any problems are detected during the execution of concordance, the function should return the NULL pointer
Step 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