I saw the answer in one of the solutions and I cannot figure out how they got the answer. The question is asked if the word is in the language or not for CNF...
How did they get the answer so that ab is in the language and aaaa is not in the language here ?
S -> aSb |ab
ab Yes
aaaa No
aabb Yes
edit:
is aaaa No because it has b in aSb and ab is yes because obviously ab is there in aSb |ab
also aabb is in the language because of aSb cause you would add same amount of a's and b's to both sides