Seminar Topics - Scholarships - Admission/Entrance Exam Notifications USA-UK-Australia-Germany-France-NewZealand Universities List Engineering-MBA-MCA-Medical-Pharmacy-B.Ed-Law Colleges Information www.andhracolleges.c om The Complete Information About Colleges in Andhra Pradesh www.andhracolleges.com Code No: R05220502 Set No. 1 II B.T ec h II Semest er Sup pli men tar y Exa minations, Au g/Sep 2007 DESIGN AND ANALYSIS OF ALGORITHMS (Computer Science & Engineering) Time: 3 hours Max Marks: 80 Answer any FIVE Questions All Questions carry equal marks ⋆ ⋆ ⋆ ⋆ ⋆ 1. (a) Explai n the asymptotic notations used in algori thm ana lys is. (b) Prove that f(n )=0 (h( n)) where f(n )=0 (g( n)) and g(n )=0(h(n)). [10+6] 2. (a) List some of the relative advantage s and disadvantage s of the parti tio n algo- rithm (b) Write the Quicksort algorithm? Anal ize the time comp lexity in worst case. [6+10] 3. (a) How many comparisons of edge weights will be done by the minimum spanning tree algorithm, in total, if the input is a complete undirected graph with n vertices and v i is the start vertex. (b) Design a linear- time algorit hm for solving the single source shor test path algo- rithm for directed a cyclic graphs represented by their adjacency linked lists. [6+10] 4. (a) Sol ve the fol lowing 0/1 Knapsa ck pro blem us ing dynamic programmin g m=6, n=3, (w 1 ,w 2 ,w 3 )=(2,3,3), ( p 1 , p 2 , p 3 )=(1,2,4) (b) Write an algorithm of all pairs shortest path problem. [8+8] 5. (a) Write a pseudocode for finding the strongly connected components of directed graph. Also analyze its time complexity. (b) Explain the Inorder traversal of a tree with an example. [8+8] 6. (a) Describe graph coloring problem and its time comple xit y. (b) Wri te an al go ri thm of 8-quee ns problem using backtracki ng . [8+8] 7. (a) What i s Boun ding? Explain ho w thes e bound are usef ul in Branch and Bound methods. (b) Describe the TSP in Branch and Bound. [8+8] 8. (a) Explai n about cook’s theo rem. (b) Explain the strategy to prove that a problem is NP hard. [8+8] ⋆ ⋆ ⋆ ⋆ ⋆ 1 of 1
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
8/9/2019 Sr05220502 Design and Analysis of Algorithms
USA-UK-Australia-Germany-France-NewZealand Universities List
Engineering-MBA-MCA-Medical-Pharmacy-B.Ed-Law Colleges Information
www.andhracolleges.com The Complete Information About Colleges in Andhra Pradesh
www.andhracolleges.com
Code No: R05220502 Set No. 1
II B.Tech II Semester Supplimentary Examinations, Aug/Sep 2007DESIGN AND ANALYSIS OF ALGORITHMS
(Computer Science & Engineering)Time: 3 hours Max Marks: 80
Answer any FIVE QuestionsAll Questions carry equal marks
⋆ ⋆ ⋆ ⋆ ⋆
1. (a) Explain the asymptotic notations used in algorithm analysis.
(b) Prove that f(n)=0(h(n)) where f(n)=0(g(n)) and g(n)=0(h(n)). [10+6]
2. (a) List some of the relative advantages and disadvantages of the partition algo-rithm
(b) Write the Quicksort algorithm? Analize the time complexity in worst case.[6+10]
3. (a) How many comparisons of edge weights will be done by the minimum spanningtree algorithm, in total, if the input is a complete undirected graph with nvertices and vi is the start vertex.
(b) Design a linear-time algorithm for solving the single source shortest path algo-rithm for directed a cyclic graphs represented by their adjacency linked lists.
[6+10]
4. (a) Solve the following 0/1 Knapsack problem using dynamic programmingm=6, n=3, (w1, w2, w3)=(2,3,3), ( p1, p2, p3)=(1,2,4)
(b) Write an algorithm of all pairs shortest path problem. [8+8]
5. (a) Write a pseudocode for finding the strongly connected components of directedgraph. Also analyze its time complexity.
(b) Explain the Inorder traversal of a tree with an example. [8+8]
6. (a) Describe graph coloring problem and its time complexity.
(b) Write an algorithm of 8-queens problem using backtracking. [8+8]
7. (a) What is Bounding? Explain how these bound are useful in Branch and Boundmethods.
(b) Describe the TSP in Branch and Bound. [8+8]
8. (a) Explain about cook’s theorem.
(b) Explain the strategy to prove that a problem is NP hard. [8+8]
⋆ ⋆ ⋆ ⋆ ⋆
1 of 1
8/9/2019 Sr05220502 Design and Analysis of Algorithms