I've this exercise of which I'm not very sure about my solution.
Exercise:
Define the transition table about a Turing Machine that accepts words on the {a, b} alphabet where each a is followed by only two b.
My proposed solution is:
(f stands for transition function)
- f(q0, a) = (a, q1, R)
- f(q0, b) = HALT
- f(q1, a) = HALT
- f(q1, b) = (b, q2, R)
- f(q2, a) = HALT
- f(q2, b) = ACCEPT
I came up with this after thinking in the same way as finite state machines, even if I know are different with respect to Turing Machines (no tape, no reading/writing symbols and no right/left moves).
So, my question is, which is the best way of reasoning when I have to solve these kinds of problems?
Thank for your attention!