564 views
2 votes
2 votes

Which of the following represent the minimum no. of states in DFA which accept all string of length atmost 5 ‘a’?

  • 6
  • 4
  • 5
  • 7

Answer given in 5 , how possible ?

atmost 5 a means , on seeing 6th a , we should send it to a dead state right ?

so , won't it be 7 states ?

2 Answers

0 votes
0 votes
It must not allow 6th a 5th 'a' itself must take you to dead state. Answer is 7 as we consider one dead state.
edited by

Related questions

0 votes
0 votes
1 answer
3