Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Marathwada Institute of Technology

Department of Computer Science and Engineering

SY CSE 2021-22

Design and Analysis of Algorithm

Defaulter’s Assignment

Defaulter students should solve questions from the given list:


1. Attendance < 25 % 15 questions and they need to call their parents to meet HOD. 2.
2. Attendance >= 25 % and < 60% 10 questions

3. Attendance >= 60 % and < 75 % 5 questions

1. What is an algorithm? Explain different characteristics of an algorithm. Explain space


and time complexity in an analyzing the performance of any algorithm.

2. What is heap? Build a heap of following elements: 5,3,17,10,84,19,6,22,9


Apply heap sort to sort the elements in ascending order. what is the time complexity?

3. Describe different asymptotic notations.


4. Search key x=35, x=28, x=60 using binary search and linear search method from
following list :10, 15 25,28,35,42,55. Comment on number of comparisons required

5. Explain the working of quick sort using divide and conquer approach for the following
data: e,x,a,m,i,n,a,t,i,o,n in alphabetical order

6. Apply the merge sort for the following set of elements: 85,24,63,45,17,31,96,50
7. Discuss the time complexity of quick sort with respect to Best and Worst case.

8. Define feasible and optimal solution. What are the steps required to develop a greedy
algorithm.

9. Explain optimal merge pattern. also find an optimal binary merge pattern for the ten
files whose lengths are 28,32,12,5,84,53,91,35,3,11.

10. Find an optimal solution to the knapsack instance n=7, m=15,

(p1:p7)=(10, 5, 15, 7, 6, 18, 3) (w1:w7)=(2, 3, 5, 7, 1, 4, 1)

11. Consider the job scheduling problem where 6 jobs have a profit of (10,34,67,45,23,39)
and the corresponding deadlines (2,3,1,4,5,3). Obtain optimum schedule. What is time
complexity of algorithm?
12. Obtain Huffman code for the following data: Character= {a,b,c,d,e},
Frequency={15,7,6,6,5}

13. Given a set of activity A={a1, a2,.... a10}


Start time={1,0,2,4,3,4,7,5,8,10}, Finish time={4,5,5,6,7,7,9,10,11,12} Find set of
mutually compatible activities.
14. Compare Divide and conquer with Dynamic programming

15. Explain Matrix multiplication using Dynamic Programming


16. Explain how the 4-queens problem is solved using backtracking process.
17. Explain sum of subset problem using backtracking with example.
18. Explain class P, class NP class NPC problem in detail

You might also like