Urgently requirement to solve the project using c++ as requirement given below.
To complete this module you should complete the Module Nine Quiz and finish Assignment Nine (below). Post your Muddiest Point for this module to Piazza (remember to tag it with the correct module), this should be something in the content you don't feel confident you completely understand.
Solve it using C++ with Main function.
To gain experience with the operations involving binary search trees. This data structure as linked list uses dynamic memory allocation to grow as the size of the data set grows. Unlike linked lists, a binary search tree is very fast to insert, delete and search.
When an author produce an index for his or her book, the first step in this process is to decide which words should go into the index; the second is to produce a list of the pages where each word occurs. Instead of trying to choose words out of our heads, we decided to let the computer produce a list of all the unique words used in the manuscript and their frequency of occurrence. We could then go over the list and choose which words to put into the index.
Save your time - order a paper!
Get your paper written from scratch within the tight deadline. Our service is a reliable solution to all your troubles. Place an order on any task and we will take care of it. You won’t have to worry about the quality and deadlinesOrder Paper Now
The main object in this problem is a “word” with associated frequency. The tentative definition of “word” here is a string of alphanumeric characters between markers where markers are white space and all punctuation marks; anything non-alphanumeric stops the reading. If we skip all un-allowed characters before getting the string, we should have exactly what we want. Ignoring words of fewer than three letters will remove from consideration such as “a”, “is”, “to”, “do”, and “by” that do not belong in an index.
In this project, you are asked to write a program to read any text file and then list all the “words” in alphabetic order with their frequency together appeared in the article. The “word” is defined above and has at least three letters.
Your result should be printed to an output file named YourUserID.txt.
You need to create a Binary Search Tree (BST) to store all the word object by writing an insertion or increment function. Finally, a proper traversal print function of the BST should be able to output the required results.
The BST class in the text can not be used directly to solve this problem. It is also NOT a good idea to modify the BST class to solve this problem. Instead, the following codes are recommended to start your program.
//Data stored in the node type
TreeNode * left;
TreeNode * right;
// Two function's prototype
// Increments the frequency count if the string is in the tree
// or inserts the string if it is not there.
void Insert(TreeNode*&, string);
// Prints the words in the tree and their frequency counts.
void PrintTree(TreeNode* , ofstream&);
//Start your main function and the definitions of above two functions.
Sample Run —
Please type the text file name: Lincoln.txt
Please give the output text file name: mus11.txt
You are done! You can open the file “mus11.txt” to check.
Press any key to continue
The Gettysburg Address
Gettysburg, Pennsylvania November 19, 1863
Four score and seven years ago our fathers brought forth on this continent, a new nation, conceived in Liberty, and dedicated to the proposition that all men are created equal.
Now we are engaged in a great civil war, testing whether that nation, or any nation so conceived and so dedicated, can long endure. We are met on a great battle-field of that war. We have come to dedicate a portion of that field, as a final resting place for those who here gave their lives that that nation might live. It is altogether fitting and proper that we should do this.
But, in a larger sense, we can not dedicate — we can not consecrate — we can not hallow — this ground. The brave men, living and dead, who struggled here, have consecrated it, far above our poor power to add or detract. The world will little note, nor long remember what we say here, but it can never forget what they did here. It is for us the living, rather, to be dedicated here to the unfinished work which they who fought here have thus far so nobly advanced. It is rather for us to be here dedicated to the great task remaining before us — that from these honored dead we take increased devotion to that cause for which they gave the last full measure of devotion — that we here highly resolve that these dead shall not have died in vain — that this nation, under God, shall have a new birth of freedom — and that government of the people, by the people, for the people, shall not perish from the earth.
Upload your source and output files
(upload – do NOT zip them! – your source file: proj9.cpp with your sample run pasted as comments at the end and your output file – userID.txt)
for the assignment below.
make complete program with main function with no compilation errors and gives the perfect output also with required informations.