Week 3 - Context Free Grammars Flashcards
1
Q
What does each rule in a BNF tell you?
A
What symbols you can replace a non-terminal symbol with.
2
Q
What 4 things make up a BNF
A
a finite set of non-terminal symbols
A finite set of terminal symbols
A finite set of rules
The start variable (which is an element of the non-terminal set)
3
Q
what does it mean that BNFs are “context free”?
A
You can apply a rule to any relevant non-terminal symbol regardless of the other symbols in the string.