Algorithms Flashcards

1
Q

What search types are there?

A

Linear

Binary

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

What is an algorithm?

A

Are sets of instructions that can be followed to perform a task.

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

What is Linear search?

A

Linear search involves methodically searching one location after another until the searched for value is found.

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

What is binary search?

A

Binary search works by dividing the list in two each time until we find the item being searched for. For binary search to work, the list has to be in order. This consists of LB, MP and UP.

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

What are sorting algorithms?

A

Sorting algorithms are used to put data (usually in an array or list) in order. This may be numbers, strings, records or objects.

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

What different type of sorts are there?

A

Bubble

Insertion

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

What is bubble sort?

A

When you swap two values to make them in order. For eg B A C, the first two letters will be swapped to make the list in order to ABC. This is easy but an inefficient way of doing things.

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

What is insertion sort?

A

This consists of 2 lists (sorted and unsorted). The first item will be classed as sorted but when moved to next item there will two now in the sorted group. They will compare the values and continue to grow the sorted group.

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