ENGN132 - Chapter 5 Flashcards

Chapter 5 Key Terms and Theories

1
Q

What is a Loop?

A

A control structure that repeats a group of steps in a program.

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

Define Loop Body

A

The statements that are repeated in the Loop

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

Define Counter-Controlled Loop/Counting Loop

A

A loop whose required number of iterations can be determined before loop execution begins.

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

Define Loop Repetition Condition

A

The condition that controls the number of times the loop repeats

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

What is a Loop Control Variable

A

A variable whose value controls the loop repetition

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

What is an Infinite Loop

A

A loop that executes forever

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

What is an Accumulator

A

A variable used to store a value being computes in increments during the execution of a loop

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

State the uses of the FOR statement

A
  • Initialization of the Loop Control Variable
  • Test of the loop repetition condition
  • Change/Update the loop control variable
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is a Side Effect?

A

A change in the value of a variable as a result of carrying out an operation.

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

What is a Flag?

A

A type int variable used to represent whether or not a certain event has occurred

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

Define Root

A

Zero of a function - A function argument value that causes the function result to be zero

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

Define a Loop Boundary

A

Initial and Final values of the loop control variable

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

Define Single Buffering

A

The default case in which only one buffer is allocated

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

Define a Buffer

A

An area of memory where data to be displayed or printed is temporarily stored

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

Define Double Buffering

A

A technique used in graphics programming to reduce display flicker by allocating two buffers: the second buffer is filled while the contents of the first buffer is being displayed and then the roles of each buffer are reversed.

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