Introduction Flashcards

1
Q

What is an imperative language?

A

Imperative languages tell the computer how it should be done

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

What is a declarative language?

A

what the computer is to do

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

Which type of language is higher level? Imperative or declarative?

A

Declarative

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

What is abstraction and why is it so powerful?

A

Abstractionis the ability to control the complexity of a program including

  • high level programming
  • names
  • functions/procedures/methods
  • objects
  • functional programming
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is compilation?

A

The compiler translates the high-level source program into an equivalent target program (typically in machine language), and then goes away:

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

What is interpretation?

A

Interpreter stays around for the execution of the program

Interpreter is the locus of control during execution

Basically a line-by-line compiler

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

What is the difference between compilation and interpretation?

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

What is the job of the preprocessor?

A

Remove comments and white space

Group characters into tokens

Expands abbbreviations

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

What is just-in-time compilation?

A

Delaying compilation until the last possible moment

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

Review the phases of interpretation

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

What is scanning?

A

Dividing a program into tokens

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

Semantic analysis is concenered with what?

A

The discovery of meaning within a program

Detecting occurences of the same identifier

Tracking types of identifiers and expressions

Building and maintaining a symbol table

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

What is the difference between static and dynamic semantic analysis?

A

Static: before the program runs, usually done by the compiler

Dynamic: what must be checked during the run time of the program

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

What is the difference between a parse tree and a syntax tree?

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

What is another name for code improvement?

A

Optimization

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