in Theory of Computation
1,077 views
2 votes
2 votes

Which of the following languages is regular?

  1.  L = { bba (ba)* a^n-1 | n> 0 }
  2. L = {a^nb^n | n < 1000 }
  3. L = {a^nb^k  | n is odd or k is even }
  4. L = {wxw^R | w,x ∈(0+1)* }
  1. 1, 3 and 4
  2. 2, 3, 4
  3. 2, 3
  4. 1, 2, 3, 4
in Theory of Computation
1.1k views

4 Comments

my mistake 2nd one is true just make 1000 states which is finite
0
0

@rahuljai in the link mentioned they have considered WcW(R) where c is a single character, so in that case it is not possible to be regular language. In this case I think it is regular and solution is (0+1)*

0
0

@

@

2nd is definitely regular ,because it is finite and every finite language is regular

Sorry, previously I have not read all the options focused only on 1 and 4

answer should be D

https://gatecse.in/identify-the-class-of-a-given-language/

0
0

1 Answer

1 vote
1 vote
in my opinion all are regular so answer is D

reason for option 1: i dont think you need answer for that as the language can easily be written as  bba(ba)* a*

2: since you have limited the size of " n " which means that the number of comparison are finite , thus finite number of states, hence its regualr

3: the regualar expression can be written as           "  a(aa) * (bb)*  "

4: this option might be tricky as it may seem that the language is  palindrome but its not . for you just simplest term could be say w =E then wR = E thus creating  X which is ( a+ b) *   . now as you know that all the other string  will be subset of the above languge so the regualr expression of this option will be   "    (a+b)* "

1 comment

in 3 option ,are you considering and operation instead of or operation?
0
0

Related questions