0
$\begingroup$

from Sipster's definition: Any language that can be generated by some context-free grammar (call it $G$) is called a context-free language (CFL). However, can $G$ generate strings that are not in the the language that recognizes $G$?

$\endgroup$
5
$\begingroup$

By definition, the language generated by a grammar $G$ is the set of all strings generated by $G$. So a grammar generating a language $L$ can generate only words in $L$ (and conversely, it can generate all words in $L$).

| cite | improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.