Algorithm Analysis and Design S6 B.Tech CS August 2023 (S)
Algorithm Analysis and Design S6 B.Tech CS August 2023 (S)
PART A
(Answer all questions. Each question carries 3 marks)
1. Define the terms Best-case, Worst case and Average case time complexities.
2. State Master’s Theorem.
3. Explain UNION and FINDSET operations in the linked list representation of
disjoint sets.
4. List out the properties of a self-balancing tree.
5. Analyze the time complexity of merge sort algorithm using divide and conquer
strategy.
6. State fractional knapsack problem using Greedy Strategy.
7. Compare Backtracking with Branch and Bound Design Techniques.
8. What are the characteristics required by problems so that they can be solved
using dynamic programming approach?
9. Compare Las Vegas and Monte Carlo algorithms.
10. Define NP-Hard and NP-Complete classes.
PART B
(Answer one full question from each module, each question carries 14 marks)
MODULE I
11. a) Determine a good asymptotic upper bound on the recurrence T(n) =
n (7)
3T(2) + n using recursion tree method.
b) List any 3 properties of a good algorithm. Explain the Big Oh, Omega
(7)
and Theta notations with diagrams.
OR
12. a) How do you analyse recursive algorithms? Write any 2 methods to
(7)
solve recurrence equation.
b) Solve T(n)= T(n-1) +2 using substitution method. (7)
MODULE II
13. a) Define RR and RL rotations. Create a height balanced trees by
successively inserting the elements in order 42, 56,24, (10)
89,1,5,87,8,61,6,78,7,12,34.
b) Write down DFS algorithm and analyse its complexity. (4)
Page 1 of 2
C 793A4 Total Pages: 2
OR
14. a) Define strongly connected components of a graph, and write an
(8)
algorithm to find strongly connected components in a graph.
b) Differentiate between Breadth First Search and Depth First Search
(6)
Methods in a graph
MODULE III
15. a) Write the Strassen’s algorithm for matrix multiplication and use it to
compute the following matrix product, showing each step
(8)
MODULE IV
17. a) State All pairs shortest path problem. How do you solve using Floyd
(10)
Warshall algorithm, using an example.
b) State Travelling Salesman problem. (4)
OR
18. a) State Matrix Chain Multiplication Problem. Write a dynamic
(8)
programming algorithm for solving it
b) What do you mean by optimality principle? How dynamic
(6)
programming is differs from branch and bound?
MODULE V
19. a) Prove that Clique Problem and Vertex Cover Problem in NP Complete. (14)
OR
20. a) Explain Randomized Algorithms. Analyze the randomized quick sort. (10)
b) Differentiate between tractable and intractable problems. (4)
*****************************************************
Page 2 of 2