MCQ
Q.
How many strings of length less than 4 contains the language described by the regular expression (x+y)*y(a+ab)*?
Correct Answer: C
string of length 0 = Not possible (because y is always present).
string of length 1 = 1 (y)
string of length 2 = 3 (xy,yy,ya)
string of length 3 = 8 (xxy,xyy,yxy,yyy,yaa,yab,xya,yya)