Exam 6: Syntax

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

____ are symbols used to distinguish between parts of a rule.

Free
(Multiple Choice)
4.7/5
(29)
Correct Answer:
Verified

C

The lexical structure of a programming language is the structure of its ____.

Free
(Multiple Choice)
4.8/5
(36)
Correct Answer:
Verified

B

A recognizer is a program that accepts or rejects strings based on whether they have occurred before.

Free
(True/False)
4.9/5
(39)
Correct Answer:
Verified

False

Most modern languages are in a completely fixed format.

(True/False)
4.9/5
(33)

A grammar for which two distinct parse trees are possible for the same string is considered to be ambiguous.

(True/False)
4.8/5
(28)

Derivation is the process that replaces left-hand sides by choices of right-hand sides appearing in prior rules.

(True/False)
5.0/5
(37)

A grammar is considered to be context-free if ____.

(Multiple Choice)
4.7/5
(34)

In extended Backus-Naur form,square brackets [ ] indicate optional parts of the syntax.

(True/False)
4.9/5
(42)

Shift-reduce parsers shift tokens onto a stack before reducing strings to nonterminals.

(True/False)
4.9/5
(42)

____ are phrase structures that are broken down into further phrase structures.

(Multiple Choice)
4.9/5
(31)

A conflict between syntax and semantics arises when languages require certain strings to be predefined identifiers rather than reserved words.

(True/False)
4.8/5
(39)

In a regular expression,repetition is indicated by ____.

(Multiple Choice)
4.8/5
(34)

____ have been given an initial meaning for all programs in the language but are capable of being redefined.

(Multiple Choice)
4.8/5
(29)

Regular expressions can be used to describe tokens.

(True/False)
4.9/5
(38)

A context-free grammar consists of a series of ____.

(Multiple Choice)
4.9/5
(36)

The start symbol is used to identify the start of the grammar.

(True/False)
4.7/5
(34)

Backus-Naur forms are used to describe the syntax of programming languages such as Algol60.

(True/False)
4.7/5
(49)

A language is considered to be ____ when format has no effect on the program structure (other than to satisfy the principle of longest substring).

(Multiple Choice)
5.0/5
(32)

A ____ is the standard graphical depiction of syntax-directed semantics.

(Multiple Choice)
4.8/5
(42)

A ____ rule must be stated to overcome ambiguous grammars.

(Multiple Choice)
4.9/5
(41)
Showing 1 - 20 of 50
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)