2.3.1 Algorithms - Aaron Flashcards

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

What is binary search?

A

A O (log(n)) algorithm to search a sorted list for a particular item by repeatedly halving a sublist which could contain the item.

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

What is the big O for constant complexity?

A

O (1)

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

How is time complexity measured?

A

Big O notation

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

What does exponential time complexity mean?

A

The amount of time to complete an algorithm is proportional to 2 to the power of number of items inputted.

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

What does logarithmic time complexity mean?

A

The time taken to complete an algorithm will increase at a smaller rate as the number of elements inputted.

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

What is an algorithm?

A

An algorithm is a series of steps that complete a task.

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

What is the big O of a linear search algorithm?

A

O (n)

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

What is the big O of a binary search algorithm?

A

O(log(n))

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

What is the big O of a bubble sort algorithm?

A

O (n2)

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

What is a logarithm?

A

How many times a certain number is multiplied together to reach another number.

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