Chapter1 intro-1
- 4. © Oxford University Press 2014. All rights reserved.
What is an algorithm?
• An algorithm is a set of instructions to solve a given problem.
- 5. © Oxford University Press 2014. All rights reserved.
Some Examples of Algorithms in daily life
- 10. © Oxford University Press 2014. All rights reserved.
Stages of Problem Solving
• Understanding the problem
• Planning an algorithm
• Designing an algorithm
• Validating and verifying an algorithm
• Analyzing an algorithm
• Implementing an algorithm
• Performing empirical analysis (if necessary)
- 11. © Oxford University Press 2014. All rights reserved.
Computation Model
Need of Computation model
- 14. © Oxford University Press 2014. All rights reserved.
Algorithm Specification
Communication to programmer is called algorithm
specification
1. Natural Language
2. Pseudocode
3. Programming language
- 24. © Oxford University Press 2014. All rights reserved.
Deterministic Vs randomized Algorithms
- 25. © Oxford University Press 2014. All rights reserved.
Based on Design
Example Greedy, dynamic programming, Brute force
Techniques.
- 26. © Oxford University Press 2014. All rights reserved.
Based on Specialization
General Algorithms
Example; Searching and Sorting
Domain Specific Algorithms
String Algorithms
Graph Algorithms