Pregunta

If L is a language defined by : L = { awa | w ∈ {a, b}* },

is aa a string of the language L? (notice that w is being null string here)

¿Fue útil?

Solución

According to you definition it seems L consists only of two words aba and aaa.

EDIT: after you have edited the question I can say yes "aa" is a word of this language w ∈ {a, b}* means zero or more chars of this alphabet and thus w may have zero chars and be empty.

Otros consejos

Your Problem can be restated as this.

L= a(a|b)*a

Which translates into intuition as "Strings that begin with and end with 'a'". So naturally, 'aa' is a valid string.

I hope this answers your question.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top