You have an incoming bitstream (sequence of 0s and 1s) that might be truncated at any time. Your goal is to construct a DFA which identifies if the current input, at any given time, belong to a certain language L or not. That is, if x is the current bitstream, then the DFA should be in an accepting state if x is in L, and in a rejecting state if x is not in L. After another bit of the input is read, the DFA should update to an appropriate state, and so on.
L = {w I w contains an equal number of occurrences of the substrings 01 and 10}

Q&A Education