Programming languages ii - Modularity and scope Flashcards

You may prefer our related Brainscape-certified flashcards:
1
Q

Difference between function and procedure?

A

A function returns a value while a procedure does not.

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

Modularity

A

Degree of relatively independent components (modules).

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

Module

A

Part of a program.

Can contain one/several subroutines, functions or procedures.

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

Library

A

Pre-compiled subroutines incorporable into a program.

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

Global variable

A

Variable accessed within the whole duration of the program.

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

Local Variable

A

Defined & can only be used within one part of the program.

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

Scope

A

Section of code which variable can be used & has a value.

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

Function

A

Block of code within a program
Unique identifiable name,
zero or more parameters
returns single value

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

Procedure

A

Block of code within a program
Unique identifiable name,
zero or more parameters when called

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

Argument

A

Data provided to function / procedure when called

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

Pre-conditions

A

A condition that always must be true just prior to the execution of some section of code.

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