What is the number of terminal string of length <= 6 generated by the CFG shown below?
S -> 0A1
A -> BB1/B
B ->A/0/1
Do you have any semantic method to solve such questions based on some pattern that can generalizes up to any length string n ??
For the present question it is 6,quite simple to derive but I am wondering what if it had been asked no of strings of length n
Thanks