Professional Documents
Culture Documents
DESIGN+AND+ANALYSIS+OF+ALGORITHMS Seme1 2006
DESIGN+AND+ANALYSIS+OF+ALGORITHMS Seme1 2006
M. C. S. E. Examination 2006
(1st Semester)
1. Write an algorithm to find the kth -smallest element out of n and argue for its
efficiency.
20
2. Explain the randomized quicksort algorithm and discuss its efficiency.
20
4. What is the principle of optimality? Does it always hold? Formulate a k-stage graph
problem as a dynamic programming problem and outline a solution.
5+5+10
5. Explain the 8-Queens problem and provide an efficient backtracking solution.
20
6. Use least cost search for the 15-puzzle problem and state the condition for the solution.
20
7. Write an algorithm for Huffman code and prove its correctness
20