483 views
1 votes
1 votes

Which of the following languages is/are regular?

1 Answer

0 votes
0 votes

Option 1- It is trivial that it is regular.

Option 2

Case1When number of b is greater or equal to number of  a

In this case using only 51 state we can accept this. States will be like (# of b, #of a) which is(0,0) (1,0), (2,0), (3,0)………(50,0).

Case 2- When number of an is greater than number of b

In this case, we can not accept input string using finite state automata. 

Because there is an infinite number of cases possible which should be accepted. (0,1), (0,2)………….(0,∞), (1,2), (1,3)…...∞) likewise. For all these, # of b – # of a is less than 50.

So option 2 is false.

Related questions

5 votes
5 votes
3 answers
1
Hirak asked May 25, 2019
1,812 views
Consider the following statements:$S_1:\{(a^n)^m|n\leq m\geq0\}$$S_2:\{a^nb^n|n\geq 1\} \cup \{a^nb^m|n \geq1,m \geq 1\} $Which of the following is regular?$S_1$ only$S_2...
0 votes
0 votes
1 answer
4