0% found this document useful (0 votes)
77 views7 pages

DAA Question Bank

Uploaded by

suprajdeshik
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
77 views7 pages

DAA Question Bank

Uploaded by

suprajdeshik
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 7

UNIT-I

1. Derive the recurrence relation of the following algorithm is (2M)

2. Solve T(n)=3T(n/3)+√n(2M)

3. Prove 3n3+ 2n2= O(n)3 ; 3n !=O(2n ). (2M)


4. Solve the recurrence using masters theorem : T(n) = 6T(n/3)+n2 logn(2M)

5. Define order of growth (2M)


6. Distinguish between Algorithm and Pseudocode.(2M)
7. Define i) Time Complexity ii) Space Complexity (2M)
8. Explain the properties / characteristics of an algorithm with an example.( (5M)
9. Explain recursive functions algorithm analysis with an example.(5M)
10. Explain the Asymptotic notations with example.
11. What is DFS and list its applications?(2M/3M)
12. Give the algorithm for transpose of a matrix m x n and find the time complexity of the
algorithm using step count method.(3M/5M)

13. How do we analyze algorithms? Explain what is meant by space and time complexity? (5M)

14. Explain Big O,Omega and Theta notations?Explain what are they used for? (5M)

15. Discuss different ways of algorithm design with suitable example? (5M)

16. Explain the BFS and DFS algorithm with an example.(5M)


17. Explain set representation and write algorithm for ‘FIND’.(3M)
18. How to find articulation point and Bi-connected components from given graph?
UNIT-II

1. Explain partition exchange sort Quick Sort algorithm and trace this algorithm for n =8
elements: 24,12, 35, 23,45,34,20,48.

2. Explain recursive Quick sort algorithm with an example and analyze the algorithm for
average time complexity.(5M)

3. Derive the time complexity of Quick sort algorithm for worst case.(2M)

4. Write the General method and Control Abstraction of Divide – and – Conquer.(2M)

5. What is stable sorting method? Is Merge sort a stable sorting method?

6. What are the advantages and disadvantages of Divide – And – Conquer? (2M)

7. Distinguish between Merge sort and quick sort. (2M)

8. Explain Recursive Binary search algorithm with suitable examples.(5M)

9. Discuss the time complexity of Binary search algorithm for best and worst case.(2M/3M)

10. Explain steps involved in Merge sort algorithm for n =8 elements: 24,12, 35, 23,45,34,20,48
(5M)

11. Derive the time complexity of Merge sort algorithm for all cases.(2M)

12. Write a recursive algorithm for finding both the minimum and maximum elements in an
array A of n elements and Explain with an example?

13. Explain Travelling salesman problem using brute force methodology with an example.
(2M/3M)

14. What is Convex hull problem.(2M)


UNIT-III

1. Write the control abstraction for Divide and Conquer technique.(2M)

2. Write the general method and Control Abstraction of Greedy method (2M)

3. Define i) Principles of optimality ii) Feasible solution iii) Optimal solution.(2M)

4. Distinguish between Prim’s and Kruskal’s spanning tree algorithm.(2M)

5. State Principle of Optimality in Dynamic Programming.(2M)

6. Explain the algorithm for Greedy knapsack with an example and also compute the time
complexity. (5M)

7. Find an optimal solution to the knapsack instance n=7 objects and the capacity of knapsack
m=15. The profits and weights of the objects are (P1,P2,P3, P4, P5,P6, P7)= (10,
5,15,7,6,18,3) (W1,W2,W3,W4,W5,W6,W7)= (2,3,5,7,1,4,1). (5M)

8. State the Job – Sequencing Deadline Problem (2M)

9. Find an optimal sequence using greedy methodology to the n=5 Jobs where profits
(P1,P2,P3,P4,P5) = (20,15,10,5,1) and deadlines (d1,d2,d3,d4,d5) =( 2,2,1,3,3).

10. What is a Spanning tree? Explain Prim’s Minimum cost spanning tree algorithm with
suitable example and also find the time complexity. (5M)

11. Discuss the single – source shortest paths (i.e. Dijkstra’s) algorithm with suitable example
and also find the time complexity.(5M)

12. Consider the following instance of knapsack problem n = 7, m = 15 (P1, P2, P3, P4, P5, P6,
P7) = (10, 5, 15, 7, 6, 18, 3) and (W1, W2, W3, W4, W5, W6, W7) = (2, 3, 5, 7, 1, 4, 1)
solve by using Greedy approach.(5M)

13. Consider the knapsack for the instance n = 4, (w1, w2, w3, w4) = (10, 15, 6, 12)

and (P1, P2, P3, P4) = (2, 5, 8, 1) and m = 21. Generate the sets Si and find optimal solution
using dynamic programming.(5M)
14. Write recurrence relations for solving OBST using dynamic programming and construct the
tree for given data:

n=4, (a1, a2, a3,a4) = (end, goto, print, stop)

p(1:4)=(1/20, 1/5, 1/10, 1/20) q(0:4)=(1/5, 1/10, 1/5,1/20, 1/20)

Where Ps are probability of successful search and qs are probability of unsuccessful

search.(5M)

15. What is All – Pair Shortest Path problem (APSP)? Discuss the Floyd’s APSP algorithm and
discuss the analysis of this algorithm. (5M)
16. What is minimum spanning tree. Explain Kruskal’s algorithm and trace it step by step using
the graph given below.
UNIT-IV

1. What is a Backtracking and give the 4 – Queens’s solution. Draw the portion of the state
space tree for n = 4 queens using backtracking algorithm. (2M/3M)

2. Write an algorithm for N – queen’s problem. Give time and space complexity for 8 –
queen’s problem. (5M)

3. Define: i) State Space tree ii) E – Node and Iii) Dead Node. (2M)

4. Define Chromatic number & Give the state space tree for 4 – Coloring problem.Explain the
Graph – coloring problem. And draw the state space tree for m= 3 colors n=4 vertices graph.
Discuss the time and space complexity. (5M)

5. Write the Control Abstraction of iterative Backtracking method (2M)

6. What is a Hamiltonian Cycle? Explain how to find Hamiltonian path and cycle using
backtracking algorithm.(5M)

7. a) Distinguish between fixed – tuple sized and variable tuple sized state space tree
organization. (2M)

b) Define: i) LC – Search ii) Branch and Bound (BB) iii) FIFO – BB. (2M)

c) Write the Control Abstraction of Least – Cost Branch and Bound. (2M)

8. Distinguish between backtracking and branch – and bound techniques. (2M)

9. Define Bounding Function? Give the statement of 0/1 Knapsack FIFO BB and explain the
procedure with the knapsack instance for n=4.m=15,(p1,p2,p3,p4)=(10,10,12,18)
(w1,w2,w3,w4) =(2, 4, 6, 9). (5M)

10. Give the 0/1 Knapsack LCBB algorithm. Explain how to find optimal solution using
variable – tuple sized approach. (5M)

11. Explain travelling sales person person problem LCBB procedure with the following instance
and draw the portion of the state space tree and find an optimal tour. (5M)
12. b) Draw the portion of state space tree generated by LCBB for the 0/1 Knapsack instance: n
= 5, (p1,p2,…,p5) = (10,15,6,8,4), (w1,w2,..,w5) = (4,6,3,4,2) and m=12. Find an optimal
solution using fixed – tuple sized approach. (5M)

13. 4. a) Draw the portion of state space tree generated by FIFOBB for the job sequencing with
deadlines instance n=5 , (p1,p2,..,p5) =(6,3,4,8,5), (t1,t2,..t5) = (2,1,2,1,1) and
(d1,d2,..,d5)=(3,1,4,2,4).What is the penalty corresponding to an optimal solution. (5M)

UNIT-V
1. Define class P (2M)
2. Compare NP-hard and NP-completeness (2M)
3. What are NP-complete problem(2M)
4. Define deterministic problem? (2M)
5. Define non-deterministic problem(2M)
6. What is a decision problem? (2M)
7. Explain optimization problem(2M)
8. Define halting problem(2M)
9. State and prove cook’s theorem(5M)
10. Explain deterministic and non-deterministic algorithms(5M)
11. Explain how P and NP problems are related(5M)
12. Distinguish NP- hard and NP-complete problems(5M)
13. What is chromatic number decision problem and clique decision problem(5M)
14. Explain the strategy to prove that a problem is NP-hard(5M)
15. Explain 3CNF satisfiability problem(5M)

You might also like