Question: You've been hired by Readability Robins to write a C++ console application that analyzes a paragraph for readability using the ColemanLiau index. Define a paragraph

You've been hired by Readability Robins to write a C++ console application that analyzes a paragraph for readability using the ColemanLiau index. Define a paragraph of text as a constant (paragraph examples are below). Calculate and format the following twelve outputs into two formatted columns: String length. Number of alphanumeric characters. Number of punctuation characters. Number of spaces. Number of any other characters this should be zero. The sum of the previous four counts this should equal the string length. Number of sentences assume each sentence ends with a period (.). Number of words assume this is the number of spaces plus one. Number of letters in words this is the number of alphanumeric characters. L = (number of letters in words) words 100. S = sentences words 100. (ColemanLiau Index) CLI = (0.0588 L) (0.296 S) 15.8. The first column is a left-justified label. The second column is a right-justified value. Format all real numbers to two decimal places. Use a for statement to loop through the paragraph to test each of its characters. Use the boolean character functions available in Canvas app String and character functions to determine character types. Use formatted output manipulators to print the output. To test your application, use this test paragraph (which should be defined as a string constant): Existing computer programs that measure readability are based largely upon subroutines which estimate number of syllables, usually by counting vowels. The shortcoming in estimating syllables is that it necessitates keypunching the prose into the computer. There is no need to estimate syllables since word length in letters is a better predictor of readability than word length in syllables. Therefore, a new readability formula was computed that has for its predictors letters per 100 words and sentences per 100 words. Both predictors can be counted by an optical scanning device, and thus the formula makes it economically feasible for an organization such as the US Office of Education to calibrate the readability of all textbooks for the public school system.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!