lOMoARcPSD|25444167
FLA Unit 4 - Question Bank
formal language and automata (SRM Institute of Science and Technology)
Scan to open on Studocu
Studocu is not sponsored or endorsed by any college or university
Downloaded by Tushar Dineshprabhu (
[email protected])
lOMoARcPSD|25444167
UNIT-4
1. The estimation of n if Turing machine is characterized utilizing n-tuples:
a) 6 b) 8 c) 5 d) 7
2 Which of the statement is valid for the language
(a) It is not accepted by a Turing Machine
(b) It is regular but not context-free
(c) It is context-free but not regular
(d) It is neither regular nor context-free, but accepted by a Turing machine
3. Which of the following isn't right regarding potential results while executing a Turing Machine
for a given input?
a)it may halt and accept the input
b)it may halt by changing the input
c)it may halt and reject the input
d) It may never halt.
4. What is the purpose for a Turing machine is more impressive than
FSM
a) Turing machine head movement is continued to one direction.
b) Turing machine head moment is in both directions i.e. left moment
and right moment as well.
c) Turing machine has capability remember arbitrary long sequence
of input string.
d) All are correct.
5. A Turing machine with a few tapes in known as
a) Multi-tape turing machine
b) Poly-tape turing maching
c) Universal turing machine
d) Non Deterministic Turing Machine
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
6. A Multitape Turing machine is ________ powerful than a single tape Turing machine.
a) More b) less c) equal d) none of the mentioned.
7.Which of the following is not a Non deterministic Turing machine?
a)Alternating Turing machine
b)Probabalistic Turing machine
c)Read only Turing machine.
d)None of the mentioned.
8. Which of the following is true about Turing’s a-machine?
a) a stands for automatic
b) left ended, right end-infinite
c) finite number of tape symbols were allowed
d) all of the mentioned.
9. According to Chomsky hierarchy, which of the following is adopted by Recursively
Ennumerable language?
a) Type 0 b) Type 1 c) Type 2 d) Type 3
10. An instantaneous description of Turing machine consists of
a) Present state and input to be processed
b) Present state and entire input to be processed
c) Present input only
d) Previous State and input to be processed.
11. Let L1 be a recursive language, and let L2 be a recursively enumerable but not a recursive
language. Which one of the following is TRUE?
L1' --> Complement of L1
L2' --> Complement of L2
(A) L1′ is recursive and L2′ is recursively enumerable
(B) L1′ is recursive and L2′ is not recursively enumerable
(C) L1′ and L2′ are recursively enumerable
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(D) L1′ is recursively enumerable and L2′ is recursive
12. Every language accepted by a k-tape TM is _____ by a single-tape TM.
a) accepted
b) not accepted
c) generated
d) not generated
13. State true or false:
Statement: We can use the finite control of turing machine to hold a finite amount of data.
a.true b.false c.may be d.can't say
14. Which of the following statements is/are true?
a) Every multitape Turing machine has its equivalent single tape Turing machine
b) Every multitape Turing machine is an abstract machine
c) Both a and b
d) Multitape Turing machine is more powerful than Single tape Turing machine
15. In multi head Turing machine there are
a) More than one heads of the Turing machine
b) More than one input tapes of Turing machine
c) Similar to the basic model of Turing machine
d) All of these.
16. Which of the following is the restricted model of Turing ma chines
a) Turing machine with semi-infinite tape
b) Multi stack machine
c) Offline Turing machine
d) Both (a) and (b)
17. A pushdown automata behaves like a Turing machine, when it has number of memory.
a)0
b)1
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
c)exactly 2
d)2 or more.
18.A FSM can be converted to be a ______________ of finite tape length without rewinding
capability and unidirectional tape movement
a)Turing Machine
b)Push Down Automata
c)Context Free Language
d)Regular Language
19. Which of the accompanying proclamation isn't right?
a) An Finite state Machine can be converted to be a Turing of finite tape length ,
rewinding capability and unidirectional tape movement.
b) Palindromes can’t be recognised by any FSM because an FSM can’t deterministically
fix the mid point.
c) Palindromes can’t be recognised by any FSM because even if the midpoint is known, an FSM
can’t find whether the second half of the string matches the first half.
d) Palindromes can’t be recognised by any FSM because an FSM can’t remember arbitrarily
large amount of information.
1820.If Turing machine accepts all the words of the languages L and rejects or loops for other
Words which are not in L, then L is said to be
a)Recursive enumerable
b)Recursive
c)Context Free Language
d)Context Sensitive Language
PART-B
1.A single tape Turing Machine M has two states q0 and q1, of which q0 is the starting
state. The tape alphabet of M is {0, 1, B} and its input alphabet is {0, 1}. The symbol B is
the blank symbol used to indicate end of an input string. The transition function of M
is described in the following table
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
0 1 B
q0 q1, 1, R q1, 1, R Halt
q1 q1, 1, R q0, 1, L q0, B, L
. Which of the following statements is true about M ?
a)M does not halt on any string in (0 + 1)+
b)M does not halt on any string in (00 + 1)*
c)M halts on all string ending in a 0
d)M halts on all string ending in a 1
2.Given a TM M=({q0,q1},{0,1}{0,1,B} δ,B,{q1})
Where δ is a transition function defined as
δ(q0, 0) = (q0,0, R)
δ(q0, B) = (q1,B, R)
which of the following string is accepted by this Turing Machine
(i)001 (ii) 010 (iii)000 (iv) None of these
3. 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)
δ(q3, b) = (q3, b, R)
The language L(M) accepted by the Turing Machine is given as
(i)aa*b
(ii)abab
(iii)aba*b
(iv) aba*
4.Given a TM M=({q0,q1},{0,1}{0,1,B} δ,B,{q1})
Where δ is a transition function defined as
δ(q0, 0) = (q0,0, R)
δ(q0, B) = (q1,B, R)
which are of the following Regular Expression accepted by this TM
represent the strings
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(i)01* (ii) 000* (iii) 10* (iv) 00*
5.Given a Turing Machine M = ({q0, q1, q2, q3, q0, q4, q5, q6, q7 }, {a, b}, {a, b, B}, δ, B, {q7})
Which of the following language accepts?
a)It accepts language of palindrome over {a,b}* with each string of even length.
b) It accepts language of binary addition over {a,b}*
c) It accepts language of palindrome over {a,b}* with each string of odd length.
d) It accepts language of binary subtraction over {a,b}* where a>b
6.Which of the accompanying Turing Machine resembles the given transition graph
(i)Turing Machine for copying data
(ii) Turing Machine for adding 2 numbers
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(iii) Turing Machine for subtracting two numbers
(iv) Turing Machine for reverse a String
7. What does the following transition graph shows
(i)Turing Machine for copying data
(ii) Turing Machine for adding two unary numbers
(iii) Turing Machine for subtracting two unary numbers
(iv) Turing Machine for reverse a String
8. What does the following state transition graph shows
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(i) Turing machine for anbncn | n ≥ 1
(ii) Turing machine for anbmcn | n,m ≥ 1
(iii) Turing machine for anbncn | n ≥ 2
(iv) Turing machine for anbmcn | n ,m≥ 2
9.Here is a description of a TM M=({q0,q1},{0,1}{0,1,B} δ,B,{q1})
The transition function δ is given below
δ(q0, 1) = (q0,1, R)
δ(q0, B) = (q1,1, R)
δ(q1, B) is a accepting state
The following TM acts like
(i)copies a String
(ii)Successor function of a unary number
(iii)Reverse a string
(iv)Accepts a Palindrome.
10. Which of the accompanying articulation is right for the state transition diagram
(i) Turing machine acts for 1's complement.
(ii) Turing machine acts comparator
(iii) Turing machine acts for 2's complement.
(iv) Turing machine accepts as a Palindrome.
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
PART C
1.The Turing machine M is defined by the state diagram
(1.1)The computational result for the input string “aabca”
(i)q2BccbbcB (ii)q2BcbcbcB (iii)q2BaccbaB (iv)q2BbbaabB
(1.2)The computational result for the input string “bcbc”
(i)q2BbbbbB (ii)q2BcbcbB (iii)q2BccbbB (iv)q2BbbcbB
(1.3).Describe the result of above computation in M
(i)substitute the a’s in the input string with c’s and the c’s with b’s.
(ii) substitute the a’s in the input string with b’s and the b’s with a’s.
(iii) substitute both b’s and c’s in the input string with a’s
(iv) substitute the b’s in the input string with a’s and the c’s with b’s.
(1.4)The state diagram for the machine M
(i)
(ii)
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(iii)
(iv)
Answer:option(i)
2. Identify the correct Turing machine with input alphabet {a, b} to accept for the Strings
with the equivalent number of a's and b's
(i)
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(ii)
(iii)
(iv)
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
Answer:Option (iv)
{uuR | u ∈ {a, b}}
(i)
(ii)
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(iii)
(iv)
Answer:option(i)
4. The Turing machine described in the below Transition table as
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(4.1)The result for the first six state transitions of the input string “abab”
(i) BababBq1
(ii)Babbq2aB
(iii) Baaq1abB
(iv) BababBq2
(4.2) The computation for the input string “abcab”.
(i) bbcab
(ii)acbcb
(iii)ccacb
(iv)bacab
(4.3) Narrate the result of a computation in M.
(i) Delete the a’s before the first c with b’s and the b’s before the first c with a’s.
(ii) Replace the a’s before the first c with b’s and the b’s before the first c with a’s.
(iii) Erase the a’s before the first c with b’s and the b’s before the first c with a’s.
(iv) Insert the a’s before the first c with b’s and the b’s before the first c with a’s.
(4.4)Give the state diagram of the given TM.
(i)
(ii)
(iii)
(iv)
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
Answer:option(iv)
5.What does the following Transition diagram with input alphabet {a,b} shows
(i) {aibj | i ≥ 0, j ≥ i }
(ii) { aibj aibj | i, j > 0}
(iii) { uu | u ∈ {a, b}}
(iv) { aibj | i ≥ 0, j ≥ 0}
(6.1) Given Turing machine M with input alphabet {a, b}and input configuration q0BuB does
perform which of the following operations. .
(i) Shift the input one space to the left..
Downloaded by Tushar Dineshprabhu ([email protected])
lOMoARcPSD|25444167
(ii) It reverse the given input
(iii) Shift the input one space to the right
(iv) The input remains same.
(6.2) Given Turing machine M with input alphabet {a, b}and initial configuration
q0BbabaababB does perform which of the following operations
(i) Erase the a’s from the input
(ii) Insert .one a’s in the input
(iii) Include .one b’s in the input
(iv) Erase the b’s from the input.
Downloaded by Tushar Dineshprabhu ([email protected])