Programming Language 6.1 - 6-6

¡Supera tus tareas y exámenes ahora con Quizwiz!

Start symbol

"st"

language of the grammar

a context free grammar defines a langauge

Start Symbol

a context-free grammar also has a special nonterminal

scanning

a translator collects sequences of characters from the input program and forms them into tokens

context-free grammar

consists of a series of grammar rules

regular expression

descriptions of patterns of characters

production

grammar rules, strings of the language using derations

predefined identifiers

identifiers that have been given an initial meaning for all programs in the language but are capable of redirection

Backus-Naur form

if they they are as given using only the metasymbol "=>" and "|".

free-format

is one in which format has effect on the program structure( other than to satisfy the principle of longest substring).

nonterminals

names for phrase structures, since they are broken down into further phrase structures

Principle of longest substring

process of collecting the longest possible string of nonblank characters

metasymbol

serves to separate the left-hand side from the right-hand side of a rule

derivation

start with the symbol sentence(the Start symbol for the grammar) and proceed to replace left-hand sides by choices of right-hand sides in the the foregoing rules.

literal/constants

such as 42(a numeric literal) or "hello"(string literal)

Reserved word/Keywords

such as if and while

token delimiters/white space

the principle of longest substrung requires that certain tokens be separated

Lexical Structure

the structure of the tokens, or words, of a language

Parsing

the translator then processes these tokens, thereby determining the programs' s syntactic structure

fixed format

which all tokens must occur in a pre-specified location on the page

terminals

words or token symbols that cannot be broken down further


Conjuntos de estudio relacionados

EXTRA QUESTIONS LIFE BASICS AND TAXES

View Set

Unit 2: Legal Concepts of Insurance Review

View Set

Chapter Quiz - Policy Provisions and Contract Law

View Set