2.1 algorithms Flashcards

1
Q

Whats abstraction?

A

When you remove unnecessary details

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

What’s decomposition?

A

Break down a complex problem into smaller parts

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

Whats algorithm thinking?

A

A way of getting to a solution by identifying individual steps needed

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

Flowchart symbols (diamond, rectangle, parallelogram, oval)

A

🔷=desision
Rectangle=process
Parallelogram=input/outut
🟡=terminal

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

Binary search?

A

1234567 looking for 5
Go to the middle
1234567 5>3
Go to the middle of the right side as it’s bigger
1234567 5<6
1234567 5

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

Linear search?

A

1234 Looking for 3
1==3? No
2==3? No
3==3? Yes

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

Bubble?

A

3241
2341
2341
2314. 1st pass
2314
2314
2134. 2nd pass
2134
1234 3rd pass

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

Merge?

A

2134
↙️↘️
12. 34
1 2 3 4
1234

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

Insertion?

A

11 2 21 -2
11 2 21 -2
2 11 21 -2
2 11 21 -2
-2 2 11 21

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