0% found this document useful (0 votes)
24 views6 pages

Update Question Bank(DAA)

paper
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views6 pages

Update Question Bank(DAA)

paper
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

NAME OF PROGRAMME: B.

TECH (CSE)
SEMESTER / YEAR: 5TH /3RD
SUBJECT NAME (SUBJECT CODE): DAA/KCS-503

Course Outcome: for example, only


CO 1: Design new algorithms, prove them correct, and analyze their asymptotic and absolute runtime
and memory demands.
CO 2: Find an algorithm to solve the problem (create) and prove that the algorithm solves the problem
correctly (validate).
CO 3: Understand the mathematical criterion for deciding whether an algorithm is efficient, and know
many practically important problems that do not admit any efficient algorithms.
CO 4: Apply classical sorting, searching, optimization and graph algorithms.
CO 5: Understand basic techniques for designing algorithms, including the techniques of recursion,
divide-and-conquer, and greedy.

SECTION-A (Very Short Answer Type Questions)


Note: 10 questions from each unit as per 2 marks.

UNIT-I
a) What do you mean algorithms? CO1

b) What is time complexity? CO1

c) Explain Omega (Ω) notation? CO2

d) What is recurrence relation? CO1

e) Explain how algorithms performance is analyzed? CO3

f) What is Analyzing algorithm? CO2

g) What is big omega? CO1

h) What is g(n) form f(n)=2n 3 +3n 2 +1. CO2

i) What is linear sorting? CO2

j) What is asymptotic notation? CO3

UNIT-II
a) What is Red Black tree? CO1

b) Explain Skip list in brief. CO2

c) Write down the properties of binomial tree. CO2

d) Explain left rotation in RB tree. CO2

e) Explain about convex Hull. CO1

f) Write down the properties of Fibonacci Heap. CO3


g) Define Binary heap. CO2

h) Describe the properties of Red-Black tree. CO2

i) Describe Fibonacci Heaps. CO2

j) Properties of Fibonacci heap. CO1

UNIT-III
a) Compare dynamic and greedy programming strategies. CO2

b) Define MST. CO2

c) What do you mean about conquer? CO2

d) Explain searching technique using divide and conquer approach. CO2

e) Explain Greedy programming in brief CO2

f) Explain about Knapsack problem. CO3

g) Define about searching. CO1

h) Write notes any one: (i) DFS (ii) BFS CO2

i) Write notes any one: (i) Prim’s algo (ii) Kruskal ‘s algo CO1

j) What is resource allocation? CO2

UNIT-IV
a) Write application of Dynamic programming. CO1

b) What is Graph coloring? CO2

c) Explain about searching in graph. CO3

d) Differentiate Backtracking algorithm with branch and bound algorithm. CO4

e) Explain resource allocation. CO5

f) Write the Hamiltonian cycle. CO2

g) What is Backtracking? CO1

h) Define travelling salesman problem in detail. CO3

i) Describe N-Queen problems. CO4

j) Explain about TPS. CO5

UNIT-V
a) Write an algorithm for naive string matcher? CO2

b) Explain NP-complete. CO3


c) Explain NP-Hard. CO4

d) Explain Randomized algorithm. CO5

e) Explain Fast Fourier Transform in brief. CO1

f) What is Algebraic Computation? CO2

g) What are spurious hits and valid hits? CO3

h) Write about string matching. CO4

i) Explain about sort notes: NP-completeness CO2

j) What are Approximation Algorithms? CO1

SECTION-B & C
Note: 10 questions from each unit as per 10 marks or 5 marks.

UNIT-I
a) Solve the following recurrence relation: CO4

a) T (n) = 2T(n/2) + n if T (1) =1, T (n) = 2T(n/2) + n, if T (1) =1,

b) T (n) = 2T(n/2) + n2 if n>1, T(n)=1 if n=1.

c) T (n) = 2T(n/3) +T (2n/3) + c n if n>1, T(n)=1 if n=1.

d) T (n) = 3T(n/4) + cn2 using recursion tree method.

e) T (n) = 4T(n/2) + n2 using recursion tree method.

f) T (n) = T(n/4) +T (n/2) + n2 using recursion tree method

b) Describe Growth of Functions. Explain its types with suitable example. CO3

c) Write Heap sort algorithm. and arrange the no. in increasing order using HEAP Sort CO4
algorithm. 3,6,8,1,4,5,9,7,2

d) Write an algorithm of Quick algorithm. CO3

e) Arrange the no. in increasing order using shell sort algorithm. 11,88,22,77,33,66,44,55 CO4

f) Arrange the no. in increasing order using Quick sorting algorithm. 9 ,4 ,10 ,1 ,2 ,4,7.3,8 CO5

g) Write Merge sort algorithm and sort the following sequence {23, 11, 5, 15, 68, 31, 4, 17} CO3
using merge sort.

h) Calculate time complexity for T(n)=9t(n/3) +n using Master Method. CO4

i) Illustrate the operation of counting sort on the following array: A= {6, 0, 2, 0, 1,3, 4, 6, 1, CO3
3, 2}
j) Describe of Master Method for recurrence problem. CO3

UNIT-II
a) Describe the Fibonacci heap algorithms with example. CO2

b) Write an algorithm for insertion of key in the Red-Black Tree. Discuss the various cases CO5
for insertion of key in red-black tree for given sequence of key in an empty red-black tree-
4,7,12,15,3,5,14,18,16,17.

c) Explain and write an algorithm for union of two binomial heaps and create binomial heap CO4
for 7,2,4,17,1,11,6,8,15.

d) Show the results of inserting the keys 20,30,35,85,10,55,60,25,5,65,70,75,15,40,50, 80,45 CO4


in order into an empty B-tree. Use t=3, where t is the minimum degree of B- tree.

e) Describe the binomial heap algorithms with example. CO3

f) Create the red black tree: 4,7,12,15,3,5,14,18,16,17.13,11 CO4

g) What is skip list? Explain the Search operation in Skip list with suitable CO3
example also write its algorithm.
h) Describe Red-Black tree with explain any example. CO3

i) Describe B- tree with explain any example. CO3

j) Write an algorithm for deletion of Red Black tree. CO3

l Also show that a red-black tree with n internal nodes has height at most 2 log (n+1).

m What are the various differences in Binomial and Fibonacci Heap?

n Extract of Fibonacci heap.

UNIT-III
a) Define minimum spanning tree (MST). Write Prim’s algorithm to generate a MST for CO4
any given weighted graph. Generate MST for the following graph using Prim’s
algorithm.

b) Calculate the matrix chain multiplication: 20,30,50,10,5 CO3

c) Explain Dijkstra’s algorithm to solve single source shortest path problem CO3

with suitable example.


d) Write notes about: a) Greedy method b) Searching c) Kruskal’s Algorithms CO5

e) Find optimal solution using 0/1knapsack approach: (V1 V2 V3 V4) = (1,2,5,6) and (W1 W2 CO4
W3 W4) = (2,3,4,5) if maximum limit 8kg.
f) What is single source shortest paths? Write down Dijkstra’s algorithm for it. CO3
g) Discuss greedy approach to an activity selection problem of scheduling several competing CO3
activities. Solve following activity selection problem S = {A1, A2, A3, A4, A5, A6, A7}
Si = {10,5,15,7,6,18,3} Fi = {2,3,5,7,1,4,1}
h) What is Knapsack problem? Solve Fractional knapsack problem using greedy CO2
programming for the following four items with their weights w = {3, 5, 9, 5} and
values P = {45, 30, 45, 10} with knapsack capacity is 16.

i) Write the Bellman Ford Algorithm & find out the shortest path using Bellman Ford CO5

Algorithm (Figure 2). If source P.


j) Write down the Bellman Ford algorithm to solve the single source shortest path CO2
problem also write its time complexity.

UNIT-IV
a) Explain about Dynamic Programming approach. CO2

b) Explain the Floyd War shall algorithm with example. Which design strategy the algorithm CO2
uses?

c) What is TSP? Explain with perfect example. CO2

d) Discuss n queen’s problem. Solve 4 queen’s problem using backtracking method? CO4

e) What is sum of subset problem? Draw a state space tree for Sum of subset problem using CO2
backtracking? Let n=4, m=8 and w [1:4] = {1,3,4,5}.

f) Explain the method of finding Hamiltonian cycles in a graph using backtracking CO3
method with suitable example.
g) What is the difference between Backtracking a Branch & Bound? CO3

h) Explain about: a) Graph coloring b) Sum of Subsets CO2

i) Describe Resource Allocation Problem with any example. CO5

j) Explain TPS with any example using Back Tracking Algorithm. CO2

k) Find the longest common subsequence path from X=<A, B, C, B, D, A, B> and Y=<B, D, CO4
C, A, B, A>.

l What is the sum of subsets problem? Let w= {5,7,10,12,15,18,20} and m=35. Find all CO4
possible subsets of w that sum to m using recursive backtracking algorithm for it. Draw the
portion of the state-space tree that is generated.
UNIT-V
a) Write down the detailed note on Naive string-matching Algorithm. CO4

b) Write down the detailed note on N-P completeness. CO4

c) Write KMP algorithm for string matching with complexity? Perform the KMP algorithm CO4
to search the occurrences of the pattern abaab in the text string abbabaabaabab.

d) Write Rabin Karp string matching algorithm. Working modulo q=11, how many spurious CO5
hits does the Rabin Karp matcher in the text T=3141592653589793, when looking for the
pattern P=26.

e) Write short notes on following: CO4

(i) Randomized algorithm.

(ii) NP- complete and NP hard.

f) What is approximation algorithm? Explain set cover problem using CO4

approximation algorithm.

g) Write down the detailed note on Randomized Algorithm. CO4

h) Explain and write the Knuth-Morris-Pratt algorithm for pattern matching also write its CO4
time complexity

i) Write and explain the algorithm to solve vertex cover problem using CO3
approximation algorithm.

j) Differentiate between NP-Complete and NP-Hard. CO3

k Explain approximation algorithm. Explore set cover problem using approximation algorithm. CO3

You might also like