4.2 Connecting Computational Thinking and Program and Design Flashcards

1
Q

Parallel Array

A

2 separate arrays which store related data on the same indexes

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

Sequential Search

A

Iterating through the array one by one until the desired number is found
O(n)

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

Binary Search

A

-Requires a sorted array
-Array is divided in half. If the targeted number is below the middle number then the first half is spilt again until the number is found and vice versa for when it’s bigger.
O (log n)

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

Bubble Sort

A

-Array is iterated
-If the number is bigger than its neighbour it is swapped
-After the iteration, the highest number is bubbled to the top
O (n^2)

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

Selection Sort

A

-The array is spilt into 2 sub-arrays
-The first sub-array has the sorted items and the second sub-array has the unsorted items
-It works by repeatedly finding the minimum element from an unsorted list and moving it to the beginning of the list.
O (n^2)

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

Collections

A

Allow to store different data types in one data structure

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

Correctness

A

Extent to which algorithm satisfies the specifciations

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

Reliability

A

Refers to the capability of the algorithm to maintain a predefined level of performance and perform all the functions under stated conditions

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

Flexibility

A

Efforts required to modify the algorithm for other purposes other than the ones that it initially developed.

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