0% found this document useful (0 votes)
26 views4 pages

Ads Mse2

ADS_MSE2
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)
26 views4 pages

Ads Mse2

ADS_MSE2
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/ 4

URR-18 Write your Roll number

KAKATIYA INSTITUTE OF TECHNOLOGY & SCIENCE, WARANGAL


(An Autonomous Institute under Kakatiya University, Warangal)
FACULTY OF ENGINEERING AND TECHNOLOGY
B. Tech. ( ECE, EEE, ME, CE, ECI ) VI Semester
Mid Semester Examination – II

U18CS611: ADVANCED DATA STRUCTURES

Time: 2 Hours] [Max. Marks : 30


Date: 26.04.2023
Note: Answer all the questions.

1. a. Define Interval trees and mention the applications of interval [1] R CO3
tree.
b. Mention the max heap properties and insert the element ‘10’ into the [1] R CO3
following given max heap tree without violating max heap property.

16

12 9
Li Li

11 2
Li Li
c. Explain how the range queries are performed efficiently. To perform [1] U_CRP CO3
range queries efficiently what is the algorithms used.
d. Define graph and Find the in-degree and out-degree of each vertex [1] R CO4
for the given graph.

A B

D C
e. How run length encoding is calculated for the given text. Find the [1] R CO4
run length encoding for the text ‘BBBBCCCAAAAADD’ ?
f. Illustrate the construction of bad match table using the Booyer Moor [1] U CO4
algorithm for the given pattern P.
P: midexam
2. a. Develop an algorithm for quick sort. Assume the first element as the [4] Ap CO3
pivot element and sort the given numbers. In the first pass what is the
low and high values for the two sub arrays.
59, 69, 15, 72, 62, 45, 32, 89, 43, 36, 12, 90
b. Make use of the Trie data structure and insert the following words [4] Ap CO3
one after the other into the trie. After inserting all the words try to
delete last, call, map.
Cat
mat

Course Coordinator Signature with Date:


Page 1 of 4
rat
maple
ramp
map
canteen
call
last
(OR)

c. Develop an algorithm for merge? Perform the merge sort on the given [4] Ap CO3
elements and show the step by step process.
59, 69, 15, 72, 62, 45, 32, 89, 43, 36, 12, 90
d. Make use of heap sort algorithm, arrange the following elements in [4] Ap CO3
descending order.
14, 45, 23, 78, 33, 23, 46, 56
3. a. Apply the graph representations on the following graph. A graph can be [4] Ap CO4
represented in various ways. Adjacency matrix or sequential
representation, Adjacency list and Adjacency multi-list or linked
representations are among them. Find these representations for the
following graph.

b. Examine the Knuth-Morris-Pratt (KMP) Algorithm to find whether 'P' [4] An CO4
occurs in 'T. 'For 'P' compute the prefix function. Given a string 'T' and
pattern 'P' as follows:
T:
a b a b c a b c a b a b a b d

P:
a b a b d

Course Coordinator Signature with Date:


Page 2 of 4
c. Apply Kruskal’s algorithm to find the minimum cost spanning tree by [4] Ap CO4
considering cost of edges for each vertex of a given graph? Find the
total cost of the result.

Examine the following graph and traverse this directed graph using
d. Breadth First Search(BFS) and Depth First Search (DFS). Compare both [4] An CO4
the techniques.

.
4. a. Make use of bitonic sequence and give the conditions to apply bitonic [4] Ap CO3
sort. Can we apply bitonic sequence on following numbers? If yes
apply bitonic sort on following numbers.
36, 46, 66, 86, 68, 50, 46, 26.
b. Construct prim's minimum spanning tree algorithm. Start Prim’s [4] Ap CO4
algorithm from vertex D for the graph given in the figure.

Course Coordinator Signature with Date:


Page 3 of 4
(OR)
c. Choose the given array and find the element 50 using Fibonacci [4] Ap CO3
search? Construct the fibonacci numbers and show the last fibonacci
number considered for the given example. Give an algorithm for
Fibonacci search.

[i] 1 2 3 4 5 6 7
ar[i] 5 8 45 50 75 80 90
Make use of Kosaraju’s algorithm and find strongly connected [4] Ap CO4
d. components of following graph. Write the step by step procedure to
illustrate it.

--- Question Paper Ends ---


Paper set by:
Faculty Name Signature Faculty Name Signature

Course Coordinator Signature with Date:


Page 4 of 4

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy