Program for Turing Machine to accept string of language given by pattern ab*c
Formal definition of Turing Machine (TM) A Turing machine is a 7-tuple, (Q, Σ, Γ, δ, q 0 , q accept , q reject ), where Q, Σ, Γ are all finite sets and 1. Q is the set of states, 2. Σ is the input alphabet not containing the blank symbol B , 3. Γ is the tape alphabet, where B ∈ Γ and Σ ⊆ Γ, 4. δ: Q × Γ→Q × Γ × {L, R} is the transition function, 5. q 0 ∈ Q is the start state, 6. q accept ∈ Q is the accept state, and 7. q reject ∈ Q is the reject state, where q reject != q accept . State Diagram Here, Q= {q 0 , q 1 , q 2 , q 3 } Σ= {a, b, c} Γ= {a, b, c, B} q s = q 0 q accept = {q 3 } q reject = { Ø } δ is given by the following transition table Transition Table: Program #include<stdio.h> #define BlankSpace '\0' int main() { char inpstr[50]; int head, state; printf("Enter String: ")...