0% found this document useful (0 votes)
70 views

Data Structures RCS305

1. The document contains a theory examination for a Data Structures course consisting of 7 sections with multiple choice and long answer questions. Questions cover topics like time and space complexity, array addressing, stack operations, tree traversals, sorting algorithms like quicksort, and graph algorithms like Prim's and Dijkstra's. 2. Students are asked to solve problems related to multi-dimensional array addressing, implementing stack operations, explaining tree traversal techniques, sorting data using quicksort, and applying Prim's algorithm to find minimum spanning trees. 3. The final sections involve problems on binary tree construction, single source shortest path finding using Dijkstra's algorithm, and implementing either AVL trees or merge sort

Uploaded by

avinas_3mar
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)
70 views

Data Structures RCS305

1. The document contains a theory examination for a Data Structures course consisting of 7 sections with multiple choice and long answer questions. Questions cover topics like time and space complexity, array addressing, stack operations, tree traversals, sorting algorithms like quicksort, and graph algorithms like Prim's and Dijkstra's. 2. Students are asked to solve problems related to multi-dimensional array addressing, implementing stack operations, explaining tree traversal techniques, sorting data using quicksort, and applying Prim's algorithm to find minimum spanning trees. 3. The final sections involve problems on binary tree construction, single source shortest path finding using Dijkstra's algorithm, and implementing either AVL trees or merge sort

Uploaded by

avinas_3mar
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/ 2

Printed Page: 1 of 2 

Subject Code: RCS305


0Roll No: 0 0 0 0 0 0 0 0 0 0 0 0 0

BTECH
(SEM III) THEORY EXAMINATION 2021-22
DATA STRUCTURES
 
Time: 3 Hours Total Marks: 70
Note: 1. Attempt all Sections. If require any missing data; then choose suitably.
SECTION A
1. Attempt all questions in brief. 2 x 7 = 14
a. Describe the terms time and space complexity.
b. Distinguish between calloc() and malloc() function.
c. Calculate the address of the 3rd element of an integer array A[6][2] using the starting
address 2000.(Assume integer takes 2 bytes).
d. Write postfix notation of infix expression a*(b+c/d).
e. Illustrate the data structure that follows LIFO order.
f. Compare complete binary and strict binary trees.
g. Write the time complexity of quicksort and bubble sorting algorithm

SECTION B
2. Attempt any three of the following: 7 x 3 = 21
a. Consider 20 X 5 two-dimensional array “marks” which has its base address = 1000
and the size of an element = 2. Calculate the address of the element, marks[18][4]

2
2

1.
03

according to row-major order and column-major order. Write the general formula for
finding the address of the multidimensional array.

24
2_

b. Describe the term stack data structures. Illustrate the implementation of different stack

5.
2P

operations with help of a program.

.5
c. Define the term BST. Explain different types of tree traversal techniques with help of
P2

d.
an example. 17
Write the Quicksort algorithm and illustrate the steps of the algorithm to sort the
Q

|1
following data: 25, 143, 454, 75, 28, 148, 435, 566, 34.
e. Apply prims algorithm to find the minimum cost spanning tree on the given graph.
55
8:
:3
13
2
02

SECTION C
-2

3. Attempt any one part of the following: 7x1=7


ar
M

(a) Illustrate the structure ofthe doubly linked list. Write an algorithm to add a new node
9-

at the end of the doubly-linked list.


(b) Illustrate the structure of the circular linked list. Write an algorithm to add a new node
|2

at the beginning of the circular linked list.

4. Attempt any one part of the following: 7x1=7


(a) Demonstrate the step-by-step conversion of the following infix expression into a
postfix expression.
A – (B / C + (D % E * F) / G)* H)
(b) Compare non-tail and tail recursion. Construct the recursion tree for solving the tower
of Hanoi problem with n=4.

1 | P a g e  
 
QP22P2_032 | 29-Mar-2022 13:38:55 | 117.55.241.2
Printed Page: 2 of 2 
Subject Code: RCS305
0Roll No: 0 0 0 0 0 0 0 0 0 0 0 0 0

BTECH
(SEM III) THEORY EXAMINATION 2021-22
DATA STRUCTURES
 
5. Attempt any one part of the following: 7x1=7

(a) Construct the binary tree using the following traversals


In-Order Traversal : D B H E I A F J C G
Post-Order Traversal: D H I E B J F G C A
(b) Construct the Huffman tree using the following (node, Frequency) pairs A 7, B 9, C
11, D 14, E 18, F 21, G 27, H 29, I 35, J 40.

6. Attempt any one part of the following: 7x1=7

(a) Write the Dijkstra algorithm. Apply the algorithm on the following graph to find the
single source shortest path. (Assume A as source).

2
2

1.
03

24
(b) Apply BFS and DFS Algorithms on the following graph.
2_

5.
2P

.5
P2

17
Q

|1
55
8:
:3
13

7. Attempt any one part of the following: 7x1=7


2
02

(a) Describe the term AVL Tree. Illustrate step-by-step construction of AVL tree using the
-2

following data.
ar

23,45,13,56,4,6,7,32,84,89,37,96
M

(b) Write a program to implement merge sort algorithm.


9-
|2

2 | P a g e  
 
QP22P2_032 | 29-Mar-2022 13:38:55 | 117.55.241.2

You might also like