Assume we have $L=\{ab\}$, then is it correct to say that $\mathbb{prefix}(L)=\{\epsilon,a,b,ab\}$ ?
I mean - is epsilon included in every prefix?
If I have $L=\{a^*a\}$, then in this case $\mathbb{prefix}(L)=\{a^*,a^*a\}$ ?
Thanks a lot!
Assume we have $L=\{ab\}$, then is it correct to say that $\mathbb{prefix}(L)=\{\epsilon,a,b,ab\}$ ?
I mean - is epsilon included in every prefix?
If I have $L=\{a^*a\}$, then in this case $\mathbb{prefix}(L)=\{a^*,a^*a\}$ ?
Thanks a lot!
Copyright © 2021 JogjaFile Inc.
The first part is incorrect since $b$ is not a prefix of $ab$. The correct answer is $\{\varepsilon, a, ab\}$.
For the second part, your writing $L = \{a^*a\}$ does not make sense. It should be $L = a^*a$ and $\text{prefix}(L) = a^*$.