1.1 Introduction Flashcards

1
Q

What is an algorithm?

A

An algorithm is finite set of steps for solving a specific problem

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

What are the characteristics of an algorithm?

A
  • Finiteness
  • Definiteness
  • Input/Output
  • Generality
  • Effectiveness (every step can be converted to a programming language)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are the categories of algorithms?

A
  • Sequential
  • Iterative
  • Selective
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the time complexity of an algorithm?

A

This is how much time is required for an algorithm to complete its execution

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

What is the space complexity of an algorithm?

A

This is how much memory is required for an algorithm to complete execution.

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

What is asymptotic analysis?

A

This is the mathematical analysis of the time or space required for an algorithm’s completion

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

What are asymptotic notiations?

A

The mathematical notations used for asymptotic analysis

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

Differentiate between the best, worst, and average case time complexity of an algorithm.

A

Best Case: The minimum amount of time required for the algorithm to complete execution

Average case: The typical amount of time required by an algorithm to complete the execution

Worst Case: The maximum amount of time required by an algorithm to complete execution

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

What are the different asymptotic notations and their uses?

A

Big Oh (O): This is the notation used to represent the upper bound or worst-case complexity of an algorithm.

Omega: This notation is used to represent the best-case scenario or lower-bound of an algorithm

Theta: This notation is used to represent both the upper and lower bounds of an algorithm

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