computation theory - Grammar for a^n -


currently studying computation theory , came t - f question :

the following grammar

s -> | sa 

produces language {a^n | n>=1}.

well not know if can that, because grammar not halt. creates bunch accept nothing. surely if had ε derivation rule.

it same having following:

example of automata accept nothing

that never comes final state.


Comments

Popular posts from this blog

javascript - Google App Script ContentService downloadAsFile not working -

javascript - Function overwritting -

php - Find a regex to take part of Email -