Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

2017-Dec CS201-316 325

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

Name of the student .) 1-•,. ; c..

i;) /,,,,_ 1"--)4v,<1,(,,r/ •


Roll no. —
NATIONAL INSTITUTE OF TECHNOLOGY HAMIRPU'
Department Of Computer Science And Engineering (CSE
END SEMESTER EXAMINATION-2017
Course - B.Tech. Semester - V
Subject - DATA STRUCTURE Code - CSO 316
Time - 3 hours Max. Marks - 60
Note : All questions are compulsory.
Q. 1 (i) Define the term Complexity. What are big-O, big-O and big-11 (5)
notations?
(ii) What is the worst case and average case time complexity of: (3)
Insertion sort,
Selection sort and .
Heap sort algo`rithms.
(iii)Define the term Abstract Data Types. (2)
Q.2 (i) Given a one-way linked list L write an algorithm to INSERT an element (4)
ITEM in L.
(ii) Write an algorithm to DELETE a node at a given location LOC, in a (4)
doubly linked list.
(iii)What are Linked Queues? Give pictorial representation. (2)
Q.3 (2)
(i) Write the in-order and post-order traversal of the given binary tree:
0

0
0 0 0
0 el 0
(ii) Given a binary tree T maintained in memory by a linked representation (5)
ROOT, INFO, LEFT and RIGHT. Write an algorithm to traverse T in
PRE-ORDER. ,
(iii)What is a B-tree? Build a B-tree of order 3 for the following elements: (3)
2, 7, 8, 37, 46, 55, 86, 96, 104,110
Q.4 (i) Find a shortest path from node a to node f using Dijkstra's algorithm: (4)
b d
4
8 f
a 2
2 '3
10 e
(ii) Given a graph G, write an algorithm to execute Depth First Search on G. (3)
(iii)What is a minimum spanning tree? Deduce a minimum spanning tree for (3)
the following graph using Kruskal's algorithm:

4110111.4 l 11A
4,410pr CO
GI CI
7

Q.5 (i) Write an algorithm to perform Bubble Sort on an array ARR with N (4)
elements.
(ii) Apply Quick sort on the following set of elements: (3)
57, 13, 23, 66, 76, 5, 90, 21, 55, 89
What is the Complexity of the same?
(iii)Write an algorithm to perform Binary Search on an array ARR with N (3)
elements.
Q.6 Explain the following terms briefly: (10)
(i) Hashing
(ii) Strong Components
(iii)AVL trees
(iv)Compaction
(v) Data Structures

You might also like