A finite state Machine (FSM) consists of states, a set of transitions, and a string of input data. In the FSM in the figure, the ovals are represent the states, and the arrows connecting them represent the transitions. The FSM is designed to determine whether a string is a valid C++ identifier, a number, or not a valid identifier. A valid C++ identifier begins with a letter, which is followed by any number of letters, digits or an underscores '_'. The strings are always separated by a comma and the input is terminated by a period. Figure 1: FSM for recognizing valid C++ identifiers This is a modification of the first programming assignment. This time you will need to store all the tokens in one of the linked lists. So again you will need to have a a program to simulate the FSM in the figure (same as before). Input will be an arbitrary long list of comma ',' separated sections of characters (tokens) terminated by a period '.'. There will not be more than 80 characters per line and no token will be divided into two or more lines (every line ends to a comma). This time if there is a command as a token your program will have to take the action to be defined for that command. The first time you encounter a token it needs to be inserted into a linked list for the correct type of token and if the same token occurs again, it needs to be removed from the list of single instances of a token and inserted into a list of tokens of certain type with multiple instances. Also you will need to implement a set of tokens that your program needs to understand as requests for output. All command are single character. The following tokens will be valid commands for this program: v - print the lists for valid identifiers i - print the lists for invalid identifiers n - print the lists for numbers k - print the lists for key words a - print all lists Note that the commands do not need to be on their own line even though they are in the example for clarity. this,2,is,o,4of,3,#sample,3,is,8,Set, v, of,2,data,4,with,6,and,atleast,3,identifiers, n, and,4of,them,arenotvalid,%identifiers, i, or,numbers,l, a,. Your output is to contain a line of output for each element in the input, output of each command is to be separated by a line: Printing valid identifiers: - Single instance: o, Set - Multiple instances: is ------------------------------------------ Printing numbers: - Single instance: 8, 6 - Multiple instanc
## Deliverables
Complete and fully-functional working program(s) in executable form as well as complete source code of all work done. Complete copyrights to all work purchased.
## Platform
unix based ,g++
## Deadline information
assignmment to be submitted for my class...i dont have time to do it!!!!