DAA Notes Cleaned
DAA Notes Cleaned
1. Introduction to Algorithms
Notes:
- Asymptotic Notations:
- Recurrence Relations:
Important Questions:
- Long: Solve the recurrence T(n) = 2T(n/2) + n using the Master Theorem.
Notes:
- Divide the problem into sub-problems, conquer them independently, and combine the results.
- Examples:
- Quick Sort: Avg. Time Complexity = O(n log n), Worst = O(n^2).
Important Questions:
- Short: Explain the difference between Merge Sort and Quick Sort.
3. Greedy Algorithms
Notes:
- Examples:
Important Questions:
4. Dynamic Programming
Notes:
- Examples:
Important Questions:
Notes:
- Examples:
Important Questions:
- Long: Write and explain the algorithm for the Hamiltonian Cycle problem.
Notes:
- Examples:
Important Questions:
7. Graph Algorithms
Notes:
- Topological Sort: Sort DAG nodes such that for every edge u -> v, u comes before v.
- Strongly Connected Components (SCC): Kosaraju's Algorithm.
Important Questions:
Notes:
Important Questions:
Notes:
Important Questions:
Additional Questions
Short Questions
1. Define time complexity and space complexity.
2. Explain the difference between Divide and Conquer and Dynamic Programming.
Long Questions