All Exams Test series for 1 year @ ₹349 only
Question

Given a Turing Machine

M = ({q0, q1, q2, q3}, {a, b}, {a, b, B}, δ, B, {q3})

Where δ is a transition function defined as

δ(q0, a) = (q1, a, R)

δ(q1, b) = (q2, b, R)

δ(q2, a) = (q2, a, R)

δ(q2, b) = (q3, b, R)

The language L(M) accepted by the Turing Machine is given as :

This question was previously asked in
UGC NET 2016 Paper 3 Computer Science and Applications Question Paper (10-Jul-2016)
The correct answer is

aba*b

A Turing machine accepts its input when it enters a final state; here the only final state is \(q_3\). Every move writes back the same symbol and moves right, so the machine simply scans the input left to right like a finite automaton.

Step 1 — From \(q_0\) the only move is on a, to \(q_1\): the input must start with a.

Step 2 — From \(q_1\) the only move is on b, to \(q_2\): the second symbol must be b.

Step 3 — In \(q_2\) every a keeps the machine in \(q_2\) (any number of a's, including none), and a b moves it to \(q_3\), where it halts and accepts.

Step 4 — The accepted strings are therefore a, then b, then \(a^*\), then b: \(L(M) = aba^*b\) (abb, abab, abaab, …).

The other expressions fail: aa*b would need a move on a from \(q_1\), which does not exist; abab is only one string of the language, not all of it; aba* never supplies the final b needed to reach \(q_3\).

aba*b option is correct.

Was this answer helpful?

Similar Questions

  1. Which of the following represents the output of the transition function(δ)

    δ (q0 , a) = (q1 , x, R)
    δ (q1 , a) = (q1 , a, R)
    δ (q1 , y) = (q1 , y, R)
    δ (q1 , b) = (q2 , y, L)
    δ (q2 , y) = (q2 , y, L)
    δ (q2 , a) = (q2 , a, L)
    δ (q2 , x) = (q0 , x, R)
    δ (q0 , y) = (q3 , y, R)
    δ (q3 , y) = (q3 , y, R)
    δ (q3 , □) = (qf , □, R)

  2. Consider the following statements:

    (A) For every regular language, we can design Turing Machine

    (B) For every context free language, we can design Turing Machine

    Which of the following is correct?

  3. Arrange the following stages of a Turing Machine (TM) operation in the correct order as they occur during computation.

    (A) Writing a symbol on the tape

    (B) Moving the tape head left to right

    (C) Reading a symbol from the tape

    (D) Transitioning to a new state based on the current state and symbol read

    (E) Halting and accepting or rejecting the input

    Choose the correct answer from the options given below :


Important Questions from Turing Machines

  1. Given a Turing Machine, M to determine whether M ever moves its head to the left when started with input W is:
  2. Which one of the following statements is equivalent to the following assertion?
    Turing machine $M$ decides the language $L \subseteq \{0,1\}^*$
  3. Which of the following represents the output of the transition function(δ)

    δ (q0 , a) = (q1 , x, R)
    δ (q1 , a) = (q1 , a, R)
    δ (q1 , y) = (q1 , y, R)
    δ (q1 , b) = (q2 , y, L)
    δ (q2 , y) = (q2 , y, L)
    δ (q2 , a) = (q2 , a, L)
    δ (q2 , x) = (q0 , x, R)
    δ (q0 , y) = (q3 , y, R)
    δ (q3 , y) = (q3 , y, R)
    δ (q3 , □) = (qf , □, R)

  4. Consider the following statements:

    (A) For every regular language, we can design Turing Machine

    (B) For every context free language, we can design Turing Machine

    Which of the following is correct?

  5. Given below are two statements: one is labelled as Assertion A and the other is labelled as Reason R 

    Assertion A: $L = \{a^n b^n c^n : n \ge 0\}$ is accepted by a linear bounded automata. 

    Reason R: Linear bounded automata's recognize exactly the class of context sensitive languages. 

    In the light of the above statements, choose the most appropriate answer from the options given below

Need Expert Advice?
Upcoming Exams
CTET
December 12, 2026
WB SET
December 13, 2026
CBSE UGC NET
December 14, 2026
CSIR UGC NET
December 19, 2026
Test Series
UGC NET img
Teaching
UGC NET (Paper 2) December 2026 Mock Test Series
799 Tests 2 Tests Free
300 Attempts
4.4(45)
English, Hindi
More Questions from UGC NET

Start Your Preparation with Prepp Mobile App

Download the app from Google Play & App Store
Download the app from Google Play & App Store
Prepp Mobile App