18CS42 Model Question Paper - 1 With Effect From 2019-20 (CBCS Scheme)
18CS42 Model Question Paper - 1 With Effect From 2019-20 (CBCS Scheme)
18CS42 Model Question Paper - 1 With Effect From 2019-20 (CBCS Scheme)
Note: Answer any FIVE full questions, choosing at least ONE question from each MODULE.
Bloom’s
Module -1 Taxonomy Marks
Level
Q.01 a Define an algorithm. Discuss the criteria of an algorithm with an example. L1 6
b What are the various basic asymptotic efficiency classes? Explain Big O,
L2 8
Big Omega and Big Theta asymptotic notations.
c Discuss about the important problem types and fundamental data structures. L2 6
OR
Q.02 a Outline an algorithm to find maximum of n elements and obtain its time
L2 7
complexity.
b Design an algorithm to search an element in an array using sequential
search. Discuss the Best case worst case and average case efficiency of this L3 7
algorithm
c Discuss adjacency matrix and adjacency list representation of graph with
L2 6
an example
Module-2
Q. 03 a Explain the concept of Divide and Conquer. Write the recursive algorithm
L2 7
to perform binary search on list of elements
b Develop a recursive algorithm to find the minimum and maximum element
L3 7
from the list. Illustrate with an example.
c Apply Quick sort on the following set of elements:
L3 6
60, 70, 75, 80, 85, 60, 55, 50, 45
OR
Q.04 a Apply Source removal method to obtain Topological sort for the Given
Graph:
L3 6
Page 01 of 02
18CS42
Module-3
Q. 05 a Apply Greedy method to obtain an optimal solution to the Knapsack
problem where Knapsack capacity m=15.
Object 1 2 3 4 5 6 7 L3 7
Weight 10 5 15 7 6 8 3
Profit 2 3 5 7 1 4 1
b What is Job sequencing with deadlines problem? For the given data, find
the optimal job sequence and maximum profit using Greedy approach.
Jobs J1 J2 J3 J4 J5 L2 6
Profits 60 100 20 40 20
Deadlines 2 2 3 1 1
c Apply Prim’s algorithm to obtain the minimum cost spanning tree for the
given weighted graph.
L3 7
OR
Q. 06 a Design Dijkstra’s algorithm and apply the same to find single source
shortest path for the given graph by considering ‘S’ as the source vertex
L3 8
L3 8
c Construct an optimal binary search tree for the following four–key set
Key A B C D L3 6
Probability 0.1 0.2 0.4 0.3
Page 02 of 02
18CS42
OR
Q. 08 a Apply Floyd’s algorithm to find all pair shortest path for the given graph
L3 7
b Find the optimal tour for sales person using dynamic programming
technique for the given graph and its corresponding edge length matrix
L3 7
c Find the shortest path from node 1 to every other node in the given graph
using Bellman-Ford algorithm
L3 6
Module-5
Q. 09 a What is the central principle of backtracking? Apply backtracking to solve
the below instance of sum of subset problem S = {5, 10, 12, 13, 15, 18} L3 7
d = 30.
b Solve the below instance of assignment problem using branch and bound
algorithm
L3 7
Page 03 of 03