Question 147: What is the regular expression of the language {w| w has length at least 3 and its third symbol is a 0}?
- ΣΣ0Σ
- ΣΣ0Σ*
- Σ* Σ* 0 Σ
- None of the above
Solution: The correct answer is option 2. The regular expression in option 1 will have exactly 4 length strings. Option 3 might have no symbols before 0 because * denotes 0 or more occurrences. Option 2 has exactly two symbols from its alphabet and third symbol is always 0, followed by any number of any symbol from alphabet.
