Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

CSCI312 Character Counter Linked List Design a program that reads in an ASCII text file (provided) and creates an output file that contains each unique

CSCI312 Character Counter Linked List Design a program that reads in an ASCII text file (provided) and creates an output file that contains each unique character and the number of time the character appears in the file. Do not sort the output. Each unique character in the file must be represented by a character frequency class instance. For this exercise, the character frequency objects must be stored in a Linked List. Read the input file character-by-character. Reading the entire file into memory is prohibited. Linked List Documentation .NET Framework Linked List (C#/VB) http://msdn.microsoft.com/en-us/library/he2s3bh7(v=vs.110).aspx Java Linked List http://docs.oracle.com/javase/7/docs/api/java/util/LinkedList.html C++ Linked List http://msdn.microsoft.com/en-us/library/802d66bt.aspx For example, given the sample input file: Hello. The output file would look like this: H(72) = 1 e(101) = 1 l(108) = 2 o(111) = 1 .(46) = 1 Where the format of the file is the character followed by the characters ASCII value followed by the number of times the character occurred in the file. The program should be able to be executed from the command line using the following syntax: programname.exe For example, counter.exe myInput.txt Count.txt Where counter.exe is the program name, myInput.txt is the input ASCII file, and the Count.txt is the output file. The character frequency class must implement the properties and methods given in the UML diagram below. Note that the actual names of the methods can vary slightly based upon the language used. For example, the method getCharacter() would be appropriate for Java and C++; however, the property get method called, Character would be appropriate for C#/VB. Continued on the next page CharacterFrequency -ch : char -frequency : int +getCharacter() : char +setCharacter(character : char) +getFrequency() : int +setFrequency(frequency : int) +increment() +Equals() : bool +ToString() : string The solutions will be graded on three components: design, development (code), and testing. Design is weighted 20% of the total grade, development is weighted 60% of the total grade, and a testing plan is weighted 20% of the total grade. You may use C++, VB, C#, or Java to implement this program as long as the following requirements are met. A C++, VB, or C# project must be created in Visual Studio 2010, 2012, 2013 or 2015. Java programs must be submitted as an Eclipse project format or provided in source code form with instructions on how to compile and run the program. Regardless of the language used, the entire project must be submitted as a single ZIP file that contains the project folder, source code, and any additional documentation. Upload your completed project to Blackboard as a single ZIP or 7z file.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Icdt 88 2nd International Conference On Database Theory Bruges Belgium August 31 September 2 1988 Proceedings Lncs 326

Authors: Marc Gyssens ,Jan Paredaens ,Dirk Van Gucht

1st Edition

3540501711, 978-3540501718

More Books

Students also viewed these Databases questions