0% found this document useful (0 votes)
51 views3 pages

Datta Meghe Institute of Engineering, Technology & Research, Sawangi (M), Wardha Assignment No.2

The document contains 10 questions related to algorithms. It asks the student to: 1) Implement binary search on an array and calculate the average number of comparisons for successful and unsuccessful searches. 2) Explain job scheduling with deadlines using an example. 3) Find the minimum spanning tree of a graph using Prim's algorithm and write the pseudocode. 4) Explain Floyd-Warshall's algorithm and implement it on a graph.

Uploaded by

Lukesh Barapatre
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
51 views3 pages

Datta Meghe Institute of Engineering, Technology & Research, Sawangi (M), Wardha Assignment No.2

The document contains 10 questions related to algorithms. It asks the student to: 1) Implement binary search on an array and calculate the average number of comparisons for successful and unsuccessful searches. 2) Explain job scheduling with deadlines using an example. 3) Find the minimum spanning tree of a graph using Prim's algorithm and write the pseudocode. 4) Explain Floyd-Warshall's algorithm and implement it on a graph.

Uploaded by

Lukesh Barapatre
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

Datta Meghe Institute of Engineering, Technology & Research, Sawangi(M),Wardha Assignment No.

2
Branch: Computer Science & Engg. Year/Sem: Third Year/ Sixth Sem

Subject: Design & Analysis of Algorithm


1) Implement the binary search on the following array And find average no. of comparisions required for successful and unsuccessful search. -6,-2,18,46,50,67,98,130.

2) Explain job scheduling with deadline with example


3) Find MCST for the following graph using Prims algorithm. And write the algorithm for same. 10
1 2

45 30 25
4 5

40 35

50
3

35 20
6

15

4) Explain the Floyd Warshalls Algorithm and implement the same on the following graph. (6)
1 4

5) Implement TSP on following matrix. Generate the path and cost of optimal path if source vertex is 2. 0 10 15 20 5 0 9 10 6 13 0 12 8 8 9 0

6) Using principle of Dynamic programming write an algorithm for chained Matrix multiplication. A = 5 x 13, B = 13 x 7, C= 7 x 89, D = 89 x 3 7) What is multistage graph? Write algorithm for backward method. Find the path between source and destination by applying backward algorithm on following graph. (
2 1 3 6 4 9 5 8 7 10 0

8) Explain three differences between greedy and divide and conquer method. 9) Write an algorithm for Longest Common Subsequence & implement LCS on the following strings: strings: X: VAIBHAV Y: BHAVANA 10) What is significance of Optimal Binary Search tree (OBST)? For the following probabilities draw the OBST by generating W, e, and r matrices. Also find the cost of OBST. Write an algorithm to construct the three matrices. (7) Probabilities: i 0 Pi Qi --0.05

1 0.10 0.05

2 0.15 0.10

3 0.10 0.05

4 0.15 0.05

5 0.10 0.10

Datta Meghe Institute of Engineering, Technology & Research, Sawangi(M),Wardha Assignment No.3
Branch: Computer Science & Engg. Year/Sem: Third Year/ Sixth Sem

Subject: Design & Analysis of Algorithm


1) What is planner graph? Explain graph coloring, and draw the solution space tree for the following graph & write the algorithm for the same. 1 2

2) Using backtracking generates Hamilton cycle on the following graph. Write algorithm for

same. Explain how one cycle can be modified into multiple cycles. (6)
1 2 3 4

3) What is backtracking? Give the at least two solutions for 8-Queens problem and write algorithm for the same & also explain the implicit and explicit constraints associated with it. 4) Explain giving suitable example P , NP, NP-C, NP-H problem and give the relation between them. 5) Explain the following NP problems w.r.t. graph i) Clique ii) Graph portioned into triangle iii) Independent set problem

You might also like