Algorithm Flashcards

1
Q

What is an algorithm?

A

A set of instruction to perform a specific task.

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

It is a well-defined step by step solution.

A

Algorithm.

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

What are the 2 ways of representing an algorithm?

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

It is a variable declaration that is placed in an oval.

A

Terminal box.

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

It represents the beginning/end of a code.

A

Terminal box.

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

More than 2 terminal boxes can exist in a code.

A

False.

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

It is used to connect symbols and indicate the flow of logic.

A

Flowlines.

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

A variable declaration in a hexagon.

A

Initialization box.

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

What is the purpose of an initialization box?

A

To declare a beginning value.

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

A variable declaration in the shape of a parallelogram.

A

Input/output box.

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

The input/output box allows…

A

reading and printing of the data.

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

A variable declaration in the shape of a rectangle.

A

Processing box.

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

The processing box operates….

A

arithmetic and data manipulation.

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

A variable declaration in the shape of a diamond.

A

Decision box.

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

This operates logic and comparisons.

A

Decision box.

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

4 examples of words used in a decision box.

A
  1. Yes
  2. No
  3. True
  4. False
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

A variable declaration similar to a process box.

A

Predefined process box.

18
Q

A predefined process box is a marker…

A

for another process formally defined elsewhere.

19
Q

A variable declaration in the shape of a circle.

A

On-page connector.

20
Q

An off-page connector allows flowcharts to connect on the same page.

A

False. On-page connector.

21
Q

A variable declaration in the shape of an upside-down pentagon.

A

Off-page connector.

22
Q

What is the purpose of an off-page connector?

A

To connect a flowchart to another page.

23
Q

“Pseudo” means…

A

False.

24
Q

A pseudocode describes an algorithm using a combination of…

A

natural and programming language.

25
Q

A pseudocode can be run.

A

False.

26
Q

Flowcharts and pseudocodes are read according to…

A

sequential operation.

27
Q

A sequential operation has no…

A

conditional or iterative processing.

28
Q

Sequential operation is read from left to right and bottom to top.

A

False.

29
Q

A conditional operation is a step where…

A

a decision must be made.

30
Q

This operation asks questions and chooses actions based on the available options.

A

Conditional operation.

31
Q

What does modulum get?

A

The remainder.

32
Q

How to structure using the modulum (mod) function?

A

“NUM mod 2 = 0”.

The remainder is 0.

33
Q

This operation is more convenient for multiple processes.

A

Case strcuture operation.

34
Q

This case is usually included in case structure operation.

A

“Default”.

35
Q

Repetition operation uses a _ mechanism which causes a _ of statements based on _ set.

A

loop, repetition, conditions

36
Q

When a loop body is executed, then…

A

there will be a change in value of at least one variable.

37
Q

Most loop mechanisms have this effect.

A

Cumulative effect.

38
Q

What is a counter?

A

A variable that determines the number of loops.

39
Q

What is an accumulator?

A

A variable used to store results of an iteration.

40
Q

It acts as a storage for the result.

A

Accumulator.

41
Q

This operation depicts a sub-routine/process.

A

Function call operation

42
Q

This is used to determine the variables needed (i.e., input, output, etc.).

A

Problem analysis.