This program takes the NFA as input and outputs the epsilon-closure of all the states. NFA is described in a text file.The comments in the are important. It plays a role during parsing. This format should be adhered strictly. Please feel free to point out any bugs.
Click Program to go to the GitHub link.
nfa.txt
//states
q0 q1 q2
//input_symbols
0 1
//start_state
q0
//final_state
q2
//transitions of the form : intial_state input final_state
q0 0 q0
q0 e q1
q1 1 q1
q1 e q2
q2 2 q2
program.c
Over 'https' the program won't be viewable. Please use 'http' or the GitHub link above.
Click Program to go to the GitHub link.
nfa.txt
//states
q0 q1 q2
//input_symbols
0 1
//start_state
q0
//final_state
q2
//transitions of the form : intial_state input final_state
q0 0 q0
q0 e q1
q1 1 q1
q1 e q2
q2 2 q2
program.c
Over 'https' the program won't be viewable. Please use 'http' or the GitHub link above.
No comments:
Post a Comment