0% found this document useful (0 votes)
5 views1 page

October 2020

Uploaded by

vaishb210788
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)
5 views1 page

October 2020

Uploaded by

vaishb210788
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/ 1

Code No: 123BP

R15
JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD
B.Tech II Year I Semester Examinations, October - 2020
DATA STRUCTURES
(Common to CSE, IT)
JN

Time: 2 hours Max. Marks: 75


Answer any five questions
All questions carry equal marks
---
TU

1.a) Distinguish between circular linked list and doubly linked list by giving one example for
each.
b) Write a C function for deleting an integer element from the singly linked list of integer
H

elements. Assume that the singly linked list of integers is already created. [7+8]

2.a) Write a C function for inserting an integer element into a circular queue of integers.
U

Assume array representation for the circular queue.


b) Convert the following infix expression into postfix form a+b*c-e/f . [8+7]
SE

3. Write a non recursive procedure for the inorder and post order traversal of a binary tree.
Assume that the binary tree of elements is already created. [15]
D

4.a) Write heap sort algorithm for sorting a list of integers in ascending order.
b) What is the time complexity of heap sort in the worst case? [8+7]
10

5.a) Compare the performance of AVL tree with binary search tree.
b) Write the Knuth-Morris-Pratt pattern matching algorithm. [8+7]

6.a) Explain with an example any one method used for representing sparse matrix.
-1

b) Write a C function for concatenating two singly linked linear lists of characters. Assume
that the two singly linked lists of characters are already created. [7+8]
1-

7. Write a C program to implement stack using singly linked list. [15]


20

8.a) Explain with an example the adjacency matrix representation of a graph also mention its
complexities.
b) Write a recursive procedure for the DFS of a graph. [8+7]
20

---ooOoo---
AM

You might also like