For this assignment, you are to write a program that computes the Flesch Readability Score for a document. The Flesch Readability Score is computed using a formula developed in the early 1940s. It measures the average sentence length in words and the average word length in syllables. Put these two numbers into a formula and get a number between 0 and 100 that shows you the difficulty of a piece of writing.
Here is the algorithm according to the original author, Rudolf Flesch, along with simplifications you should make for this project:
• "Count the words in your piece of writing. Count as single words contractions, hyphenated words, abbreviations, figures, symbols and their combinations." That is not always easy to do accurately, so if you are using the chn utility package, it is sufficient to read tokens and count each as a word.
• "Count the syllables in your piece of writing. Count the syllables in words as they are pronounced. Count abbreviations, figures, symbols and their combinations as one-syllable words." A syllable needs a vowel, so each vowel (a,e,i,o,u,y) or group of vowels counts as a syllable. However, don't count an "e" at the end of a word as a syllable (as in the word "here"). Every word must be pronounced, so there will be at least one syllable even if the rules say there are none.
• "Count the sentences in your piece of writing. Count as a sentence each full unit of speech marked off by a period, colon, semicolon, dash, question mark or exclamation point. Disregard paragraph breaks, colons, semicolons, dashes or initial capitals within a sentence." For this assignment, ignore dashes entirely and just count as a sentence text that ends in a period, colon, semicolon, question mark or exclamation point.
• "Figure the average number of syllables per word. Divide the number of syllables by the number of words."
• "Figure the average number of words per sentence. Divide the number of words by the number of sentences."
• Find the readability score. Use Flesch's formula: "Multiply the average sentence length by 1.015. Multiply the average word length by 84.6. Add the two numbers. Subtract this sum from 206.835. The balance is your readability score."
The readability score is a number, usually between 0 and 100, indicating how difficult the text is to read. Higher numbers indicate easier reading material.
here is an example of the format that should be outputted:
Here is the format of the output using the Gettysburg Address:
Source text file: [url removed, login to view]
Readability score: 61.0
Educational level: 8th and 9th grade
I will help with the extra files. I am looking for someone to do this simple project for me for $10 and it needs to be done ASAP.
freelancer จำนวน 23 คน กำลังประมูลอยู่ที่ราคาเฉลี่ย $31 สำหรับงานนี้
Hi! I can do your stuff in 2 days. I am a university student and have hands on Java programming. Also known C,C++, and other languages mention on my profile.
Hello, I'm the software developer and I'm mostly coding in Java. I can work on your project, I can start tomorrow and it shouldn't take more than 1 day. Contact me on chat here so we can discuss this more.