Edit this page Backlinks This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== NFA Python Implementation ====== Implement (in Python) an NFA class that supports the following methods: * **step(configuration)** = returns a list including all reachable configurations in //one step//. An epsilon transition is also considered a step. * **kstep(configuration, k)** = returns a list including all reachable configurations in //k steps//. An epsilon transition is also considered a step. * **accept(self, word: Word)** = True or False if the NFA accepts the given word. To simplify this task, you can use the kstep function. * **epsilonClosure(self, state: State)** = the set of all states where we can go from the current state by going through epsilon transitions * **emptyLanguage(self)** = True or False if the NFA's accepted language is the Empty Language {{:lfa:nfa_skel.rar|}}