Data Structure and Algorithms
Data Structure and Algorithms
Instructions to Candidates :—
(1) Make proper assumptions wherever necessary.
(2) All questions carry marks as indicated against them.
(3) Illustrate answers with examples wherever necessary.
1. (a) Write a 4 x 4 matrix and represent it in row - major and column major formats.
Also find the address of A[2][3] if A[0][0] = 3000. 5 (CO 1)
(b) What is the significance of different asymptotic notations ?
Represent the given function using Big O, Theta and Omega notations.
Function : 6 y 2n + n2. 5 (CO 1)
2. (a) Write an algorithm for insertion and deletion of element from Queue.
Perform the following operations using Queue data structure. Consider the
maximum number of elements that the queue can accommodate as 3 :
Delete( ), Insert(10), insert(3), insert(5), insert(8), delete( ), insert(20).
5 (CO 2)
(b) Perform infix to postfix conversion using stack data structure :
5 + 6 – 2 y 12/4
Also evaluate the obtained postfix expression using stack. 5 (CO 2)
5. (a) Give the in - order, pre - order and post - order traversal for the given Binary
Search Tree.
5 (CO 4)
(b) What are the advantages of B+ tree ? Using an example show how insertion
is performed in a B+ tree and how traversal is performed ? 5 (CO 4)
6. (a) Represent the given undirected graph using Adjacency matrix and Adjacency
list representation.
4 (CO 4)
6 (CO 4)
QVRU/RS-22 / 1229 3 55