Chapter 3 Flashcards
1
Q
What is syntax?
A
The form of a sentence.
2
Q
What is semantics?
A
The meaning of a sentence.
3
Q
How do we describe sentences?
A
Ordered strings of characters in some alphabet.
4
Q
What are lexemes?
A
Lowest level of syntactic unit.
5
Q
What are tokens?
A
Category of a lexeme.
6
Q
What does BNF stand for?
A
Backus-Naur Form.
7
Q
What is the test for language ambiguity?
A
If a sentence has at least two distinct parse trees, then the grammar is ambiguous.
8
Q
What are two broad categories of semantics?
A
Denotational and axiomatic.
9
Q
How are COBOL railroad diagrams related to BNFs?
A
Railroad diagrams are a way to illustrate BNFs.