PCCST502Semester 5
Design and Analysis of Algorithms
Computer Science and Engineering
Earlier codes: CST306, CS302
Exam over
Exam over: how the forecast did (Nov 2026)
We said: study the top 20 topics, about 45/60. The real paper gave 51/60 for those 20 topics (random picks: 36/60).
Rebuilt on 29 Nov 2026 from papers up to Jan 2024, without the Nov 2026 paper, by the automatic pipeline. Scored against the real paper. It is a past result, not a promise.
This run would not have passed our live quality check (71% of questions flagged as garbled (max 20%); its practice paper could not be filled with clean question wordings). It is shown as a record, not as a forecast to study from.
| Studied | Topics | Forecast | Random |
|---|---|---|---|
| 20% | 7 | 50% | 27% |
| 30% | 11 | 73% | 38% |
| 40% | 14 | 78% | 50% |
| 50% | 20 | 85% | 61% |
| 60% | 26 | 90% | 70% |
18 of the 41 forecast topics came in the real paper. Part B counts the better question of each pair.
Topics, ranked
The forecast's topics in ranked order, each marked with whether it came in the real paper.
- 1
Solving Recurrences: Master Theorem, Recursion Tree & Substitution Methods
- 2
Complexity Theory: P, NP, NP-Complete, Reductions & Cook's Theorem
- 3
Shortest Path Algorithms: Dijkstra & Bellman-Ford
2 past questions
- May 2023, 7 marks6a) Write Dijkstra's algorithm for single sounce shortest path. Perform its complexity analysis.
- May 2023, 5 marksWrite Floyd Warshall algorithm for all pair shortest path problem and perform its complexity analysis.
- 4
Connected Components & Strongly Connected Components (Kosaraju's Algorithm)
- 5
Dynamic Programming: Principle of Optimality, 0/1 Knapsack, Floyd-Warshall & LCS
1 past question
- May 2023, 3 marksApply greedy algorithm for fractional knapsack to find the optimal ordering for loading the items in the knapsack. Let the knapsack capacity, M:I5 Items Weight Profit I 8 24 2 9 t8 3 5 20
- 6
Divide and Conquer: Quick Sort, Merge Sort & Strassen's Matrix Multiplication
1 past question
- May 2023, 7 markswrite a divide and conquer algorithm for 2-way merge sort and perform its complexity analysis.
- 7
Branch and Bound: Traveling Salesperson Problem & 0/1 Knapsack
1 past question
- May 2023, 9 marksDefine Travelling Salesman Problem. Solve the following instance ofTSP using branch and bound technique. The cost matrix is given below: A l0 8 9 7 B l0 l0 5 6 C 8 l0 8 9
- 8
Greedy Strategy & Applications: Fractional Knapsack & Activity Selection Problem
2 past questions
- May 2023, 3 marksGive the control abstraction of Divide and Conquer algorithm design strategy.
- May 2023, 7 marksWrite the control abstraction for Gieedf design technique. Give a greedy algorithm for fractional knapsack problem.
- 9
Asymptotic Notations: Big-O, Big-Omega, Big-Theta, Little-o & Little-omega
1 past question
- May 2023, 6 marksDefine the asymptotic notations: Big Oh, Big Omega, Theta, little oh and little omega.
- 10
Minimum Spanning Trees: Kruskal's & Prim's Algorithms
1 past question
- May 2023, 7 marksGive Kruskal's algorithm for minimum cost spanning tree computation. Apply the algorithm to find the minimum cost spanning tree for the following graph
- 11
Backtracking: N-Queens, Sum of Subsets & Hamiltonian Circuit
2 past questions
- May 2023, 3 marksDistinguish the branch-and-bound technique from the backtracking technique.
- May 2023, 6 marksDefine nqueens problem. Draw the state space tree for 4-queens problem using backtracking method.
- 12
Topological Sorting (DFS Finish Times & Kahn's Indegree Algorithm)
- 13
Analysis of Non-Recursive & Recursive Algorithms: Lower Bounds & Order Statistics
2 of 3 past questions (others unreadable)
- May 2023, 8 marksDiscuss the concept of best case, worst case and average case complexity of an algorithm with linear search algorithm.
- May 2023, 7 marksGive a randomized version of quicksort algorithm and perform its expected running time analysis.
- 14
Approximation Algorithms: Vertex Cover & Traveling Salesperson Problem (TSP)
2 past questions
- May 2023, 3 marksalgorithm. Discuss the need for approximation
- May 2023, 7 marksDefine bin packing problem. Discuss the first fit strategy for solving it. State the approximation ratio of the algorithm.
- 15
Graph Traversals (DFS & BFS) & Edge Classification: traversal, first, breadth
- 16
Dynamic Programming: Matrix Chain Multiplication & Optimal Binary Search Trees (OBST): sequence, whose, dimensions
- 17
Graph Traversals (DFS & BFS) & Edge Classification: problem, colouring, graph
1 past question
- May 2023, 3 marksDefine graph colouring problem.
- 18
Dynamic Programming: Matrix Chain Multiplication & Optimal Binary Search Trees (OBST): required, a2, optimum
- 19
Recurrence Equations, Solution of Recurrence Equations: Iteration Method
- 20
Classes: Randomized Algorithms
1 past question
- May 2023, 7 marksExplain the benefits of randomized algorithm over deterministic algorithm. Discuss briefly the major categories ofrandomized algorithms. Give example for each category.
- Your 20 topics end here: 51/60 of the real Nov 2026 paper
- 21
Graph Traversals (DFS & BFS) & Edge Classification: vertex, set, let
- 22
Dynamic Programming: Matrix Chain Multiplication & Optimal Binary Search Trees (OBST): dynamic, matrix, programming
2 past questions
- May 2023, 3 marksExplain about the structure of an optimal paranthesization of matrix-chain multiplication problem.
- May 2023, 8 marksConsider the following four matrices and perform chain matrix multiplication using the dynamic programming approach. Finally give the optimal cost of multiplication and optimal parenthesization. ABCD 4x5 5x3 3x2 2x7
- 23
AVL Property
1 past question
- May 2023, 7 marksIllustrate the advantage of AVL trees with a suitable example. Discuss the various rotations required to balance the height of AVL tree during insertion and deletion.
- 24
Classes: Bin Packing
1 past question
- May 2023, 7 marksDefine bin packing problem. Discuss the first fit strategy for solving it. State the approximation ratio of the algorithm.
- 25
Graph Traversals (DFS & BFS) & Edge Classification: category, starting, order
- 26
Clearitt Learning
1 past question
- May 2023, 7 marksIllustrate the advantage of AVL trees with a suitable example. Discuss the various rotations required to balance the height of AVL tree during insertion and deletion.
- 27
Definitions of Monte Carlo and Las Vegas algorithms
- 28
Dynamic Programming: Matrix Chain Multiplication & Optimal Binary Search Trees (OBST) (other)
- 29
Graph Traversals (DFS & BFS) & Edge Classification (other)
- 30
Algorithms: Characteristics
- 31
Clearitt Learning
1 past question
- May 2023, 6 marksDefine nqueens problem. Draw the state space tree for 4-queens problem using backtracking method.
- 32
Clearitt Learning
- 33
Clearitt Learning
- 34
Why it matters?
- 35
Algorithm FirstFit(s[1..n])
- 36
Disjoint set operations
3 past questions
- May 2023, 3 marksDefine MAKE-SET(x), UNIoN(x,y) and FIND_sET(x) operations of disjoint set data structure with a suitable example.
- May 2023, 7 marksWhat are the operations supported by Disjoint Data Structure? Explain the working of Disjoint Set Data Structure for computing Connected Components of an undirected graph given in the following Figure. r
- May 2023, 7 marksPerform the following operations in the given AVL trees. I ) Insert 54 in Tree I 2) Delete 15 from Tree2.
- 37
Property 3: Transitive Property
- 38
Clearitt Learning
- 39
Comparing Polynomial Functions
- 40
Union and find algorithms
- 41
Criteria for Analysing Algorithms
The real paper (Nov 2026)
Each question with the topic the forecast had for it. Marks are as printed; in Part B a student answers one question from each pair.
- A1
Define Big-O, Big-Omega, Big-Theta with examples and graphs.
3 marksforecast topic 9: Asymptotic Notations: Big-O, Big-Omega, Big-Theta, Little-o & Little-omega
- A2
Construct AVL tree inserting 1,2,3,4,5,6; state rotation at each insertion.
- A3
Linked-list representation of UNION(5,9) for S1={2,5,7,10}, S2={3,6,9}.
- A4
Topological sort of DAG on A..I with intermediate steps.
3 marksforecast topic 12: Topological Sorting (DFS Finish Times & Kahn's Indegree Algorithm)
- A5
Apply Kruskal's algorithm to find MST of given graph.
3 marksforecast topic 10: Minimum Spanning Trees: Kruskal's & Prim's Algorithms
- A6
Write the control abstraction of backtracking.
3 marksforecast topic 11: Backtracking: N-Queens, Sum of Subsets & Hamiltonian Circuit
- A7
Define Travelling Salesman Problem. Give an example.
3 marksforecast topic 7: Branch and Bound: Traveling Salesperson Problem & 0/1 Knapsack
- A8
Differentiate Las Vegas and Monte Carlo algorithms with one example each.
3 marksforecast topic 27: Definitions of Monte Carlo and Las Vegas algorithms
- B9a
Recursion tree: T(n)=T(n/4)+T(3n/4)+cn.
5 marksforecast topic 1: Solving Recurrences: Master Theorem, Recursion Tree & Substitution Methods
- B9b
Substitution method: T(n)=3T(n/3)+cn^2.
4 marksforecast topic 1: Solving Recurrences: Master Theorem, Recursion Tree & Substitution Methods
- B10a
State Master theorem; T(n)=2T(n/4)+sqrt(n) log^2 n.
5 marksforecast topic 1: Solving Recurrences: Master Theorem, Recursion Tree & Substitution Methods
- B10b
Iteration method: T(n)=2T(n/2)+n^2.
4 marksforecast topic 19: Recurrence Equations, Solution of Recurrence Equations: Iteration Method
- B11a
BFS traversal from A, alphabetical tie-break.
4 marksforecast topic 15: Graph Traversals (DFS & BFS) & Edge Classification: traversal, first, breadth
- B11b
Explain Strassen's matrix multiplication with example; analyse complexity.
5 marksforecast topic 6: Divide and Conquer: Quick Sort, Merge Sort & Strassen's Matrix Multiplication
- B12a
DFS algorithm; analyse time complexity with adjacency list.
5 marksforecast topic 15: Graph Traversals (DFS & BFS) & Edge Classification: traversal, first, breadth
- B12b
2-way merge sort on [24,18,21,15,30,12,27,9]; recurrence and complexity.
4 marksforecast topic 6: Divide and Conquer: Quick Sort, Merge Sort & Strassen's Matrix Multiplication
- B13a
Dijkstra from A on given directed graph.
4 marksforecast topic 3: Shortest Path Algorithms: Dijkstra & Bellman-Ford
- B13b
Fractional knapsack n=4, m=25, W=(20,15,10,5), P=(40,30,25,10).
5 marksforecast topic 8: Greedy Strategy & Applications: Fractional Knapsack & Activity Selection Problem
- B14a
Write Floyd-Warshall all-pairs shortest path algorithm.
4 marksforecast topic 5: Dynamic Programming: Principle of Optimality, 0/1 Knapsack, Floyd-Warshall & LCS
- B14b
Optimal parenthesization A1A2A3: 5x4, 4x6, 6x2; min scalar multiplications.
- B15a
Define Bin Packing formally: objective and constraints.
- B15b
Items 4,8,2,6,5 (cap 10): FF, BF, FFD; compare; optimal bins.
- B16a
Minimum vertex cover and maximum clique of given 5-vertex graph.
3 marksforecast topic 2: Complexity Theory: P, NP, NP-Complete, Reductions & Cook's Theorem
- B16b
Define NP-Complete; prove Vertex Cover is NP-Complete.
6 marksforecast topic 2: Complexity Theory: P, NP, NP-Complete, Reductions & Cook's Theorem