Reputation: 1
Im totally new to JFlap and need to create a Turing machine that compares two (finite) bit strings, separated by “=”, and accepts input if the two are equal and rejects it otherwise. For example: If input is 1011=1101, with the read head furthest to the left, the machine will reject the input string. Suggestion for approach: cross out (with “X”) matching digits until you either find two digits that do not matches or all characters in the input have been turned into “X”.
I have tried several different methods but cant really understand how to compare the strings.
Different methods where I didn´t get the result i expected. Usually the machine failed as I got to the comparison.
Upvotes: 0
Views: 96