Algorithms Flashcards
1
Q
What is an algorithm?
A
A finite sequence of operations for carrying out a procedure or solving a problem.
2
Q
3 characteristics of algorithms
A
- must be UNAMBIGUOUS i.e. person or machine running the algorithm should not have to make choices
- must be DETERMINISTIC i.e. no chance of randomness involved
- must be FINITE i.e. must end
3
Q
Big O Notation
A
- it represents the complexity of the algorithm and how it scales up
- it describes the worst case scenario
4
Q
What does it mean if one algorithm has a higher order of complexity than another?
A
it will have a longer run time