Huffman Codes

Task 1: Determine the Character Frequencies Determine the frequency of each character in the given text and store it in an array. For simplicity, only lowercase letters from ‘a’ to ‘z’, upper-case letters from ‘A’ to ‘Z’, and the blank (space) are admissible as characters (see AnalyzeText). ask 2: Build the Huffman Tree Using a priority queue of binary trees, a Huffman tree is constructed for the given text. Initially, the priority queue is populated with as many as 53 individual nodes (binary trees of size 1) where each node stores a character and its frequency. The priority queue is ordered by frequency where a binary tree with a lower total frequency has a higher priority than one with a higher total frequency (see Build). Task 3: Create the Codes The final Huffman tree is then traversed in a prefix manner such that the code for each character is stored as a string of 0s and 1s, and placed in an instance of the C# Dictionary class using its associated character as the key (see CreateCodes). Task 4: Encode Using the dictionary of codes, a given text is converted into a string of 0s and 1s (see Encode). Task 5: Decode Using the Huffman tree, a given string of 0s and 1s to converted back into the original text (see Decode). To help implement your program, consider the following skeleton of code.