Consider the language in the alphabet {a,b} defined by the grammar:
What are the 5 character strings in this language. Not sure what this means? Is it:Code:<S> = a<S>a | b<S>b | a | b
aa
bb
a
b
what would the 5th one be?
Consider the language in the alphabet {a,b} defined by the grammar:
What are the 5 character strings in this language. Not sure what this means? Is it:Code:<S> = a<S>a | b<S>b | a | b
aa
bb
a
b
what would the 5th one be?
It means what are all of the strings in this alphabet that have five characters? You must think recursively since a string can be defined recursively. Figure out all of the different combinations of strings that have five characters and are valid for that grammar.