3.1.4 Sorting Algorithms Flashcards

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

How does the merge sort Algorithm work

A

It takes 2 parts pieces of data and checks to see which is bigger and arranges them, this is repeated as the list goes on

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

How does the bubble sort Algorithm work

A

Examines each set of data tat is adjacent in the string switching positions f they are out of order

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

Advantages of Bubble sort

A

Efficient is smaller and/or ordered databases

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

Advantages of Merge sort

A

Merge sort can be used with linked lists without taking up any more space.

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

Disadvantages of Merge sort

A

For small datasets, merge sort is slower than other sorting algorithms.

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

Disadvantages of Bubble sort

A

Does not deal well with a list containing a huge number of items

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