Lecture 3 - Parsing Flashcards

1
Q

A ? is a formal language used to communicate algorithms both from programmer to programmer and from programmer to machine.

Syntax

A

programming language

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

(3) A formal language consists of:

Syntax

A
  • A set of symbols
  • Rules for forming term
  • Rules for transforming terms to terms
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

(3) To use programming language effectively, the following must study and understand it from three perspectives:

Syntax

A
  • Syntax
  • Semantics
  • Pragmatics
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

?

the set of symbols and rules for forming terms

Three perspectives

Syntax

A

Syntax

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

?

the rules for transforming terms to terms

Three perspectives

Syntax

A

Semantics

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

?

using the particular constructs of the language

Three perspectives

Syntax

A

Pragmatics

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

In ?, a language is defined as a set of strings of symbols that may be constrained by specific rules.

Context Free Language

A

formal language theory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Similarly, the written ? is made up of groups of letters (words) separated by spaces

Context Free Language

A

English language

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

A valid (accepted) sentence in the language must follow particular rules, the ?

Context Free Language

A

grammar

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

?

If L and P are CFL, then L∪P is also a CFL

Closure Properties

Context Free Language

A

Union

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

?

if L and P are CFL, then LP is also CFL

Closure Properties

Context Free Language

A

Concatenation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

?

if L is CFL, then L* is also CFL

Closure Properties

Context Free Language

A

Kleene Star

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

?

can generate context-free languages.

Closure Properties

Context Free Grammar

A

Context-free grammar

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

They do this by taking a set of variables which are defined ?, in terms of one another, by a set of production rules.

Closure Properties

Context Free Grammar

A

recursively

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

?

is defined by 4 tuples as G = {V, ∑, S, P} where

Closure Properties

Context Free Grammar

A

Context-Free Grammar

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

?

is defined by 4 tuples as G = {V, ∑, S, P} where

Closure Properties

Backus-Naur Form

A

Context-Free Grammar