Now, for any given input string . If goes through a sequence of states then it produces the output sequence . According to the construction, the Mealy machine also goes through the same sequence of states but produces the following output sequence.