logo CodeStepByStep logo

WordCount

Write a method named WordCount that accepts a file name as a parameter and opens that file and that returns a count of the number of unique words in the file. Do not worry about capitalization and punctuation; for example, "Hello" and "hello" and "hello!!" are different words for this problem. Use a set as auxiliary storage.

Method: Write a C# method as described, not a complete program or class.

You must log in before you can solve this problem.

Log In

Need help?

Stuck on an exercise? Contact your TA or instructor.

If something seems wrong with our site, please

Is there a problem? Contact us.