JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD

JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD B.Tech III DATA STRUCTURES Previous Question Paper (August/September - 2024 - R16)

B.Tech | III | II | R16 | August/September - 2024

Answer PaperPaper Code: 136EVMaximum Marks: 75Time: 3 Hours

Note: i) Question paper consists of Part A, Part B. ii) Part A is compulsory, which carries 25 marks. In Part A, Answer all questions. iii) In Part B, Answer any one question from each unit. Each question carries 10 marks and may have a, b as sub questions.

Part A

1a

Write recursive algorithm to find factorial of a number.

2 marks

Answer

The recursive algorithm for calculating the factorial of a non-negative integer n is defined by the base case where 0! = 1 and the recursive step where n! = n × (n - 1)! for n > 0.

Factorial(n):
if n == 0 return 1
else return n * Factorial(n - 1)
1b

What is the space complexity of a program to insert an element into singly linked list?

3 marks

Answer

The space complexity of inserting an element into a singly linked list is O(1), which represents constant space complexity. This is because the operation only requires the allocation of a single new node to store the data and a few pointer updates, regardless of the size of the existing list. No additional data structures or recursive calls that grow with the input size are needed.

1c

What are the applications of stack?

2 marks

Answer

Sign in to view the complete answer paper.

1d

Convert the given infix expression to prefix and postfix expressions: a+b/(c*d/(e-f))

3 marks

Answer

Sign in to view the complete answer paper.

1e

What are properties of binary trees?

2 marks

Answer

Sign in to view the complete answer paper.

1f

Give an example for graph representation with adjacency matrix and adjacency list.

3 marks

Answer

Sign in to view the complete answer paper.

1g

How time complexity of binary search is less than linear search?

2 marks

Answer

Sign in to view the complete answer paper.

1h

What are the advantages and disadvantages of static hashing?

3 marks

Answer

Sign in to view the complete answer paper.

1i

What are splay trees? Give an example.

2 marks

Answer

Sign in to view the complete answer paper.

1j

What are the properties of an AVL Tree?

3 marks

Answer

Sign in to view the complete answer paper.

Part B

2

What are singly linked lists? Write an algorithm for insertion and deletion operations in singly linked lists.

10 marks

Answer

Sign in to view the complete answer paper.

OR
310 marks
a

Write an algorithm to multiply two matrices of n x m order and explain.

5 marks

Answer

Sign in to view the complete answer paper.

b

What is a recursive algorithm? Write down the recursive algorithm to generate ‘n’ Fibonacci series.

5 marks

Answer

Sign in to view the complete answer paper.

410 marks
a

Write an algorithm to evaluate a postfix expression.

5 marks

Answer

Sign in to view the complete answer paper.

b

Explain the basic operations performed on a stack.

5 marks

Answer

Sign in to view the complete answer paper.

OR
5

What are Circular queues? Write an algorithm to perform insertion and deletion operations on circular queue.

10 marks

Answer

Sign in to view the complete answer paper.

6

What are binary tree traversals? Explain with examples and also state their applications.

10 marks

Answer

Sign in to view the complete answer paper.

OR
7

What is max heap? Write an algorithm to perform insertion and deletion operations from max heap.

10 marks

Answer

Sign in to view the complete answer paper.

8

Explain selection sort method.

10 marks

Answer

Sign in to view the complete answer paper.

OR
9

With an algorithm and example, explain binary search technique.

10 marks

Answer

Sign in to view the complete answer paper.

10

What are AVL trees? Write the pseudcode to perform insert and delete operations on AVL trees and explain.

10 marks

Answer

Sign in to view the complete answer paper.

OR
11

Explain insert and delete operations on B trees with example.

10 marks

Answer

Sign in to view the complete answer paper.

About this paper

This page contains the question paper of DATA STRUCTURES from JAWAHARLAL NEHRU TECHNOLOGICAL UNIVERSITY HYDERABAD for B.Tech CSE III II, August/September - 2024, R16.

For the solved question paper with answers, switch to the Answer Paper tab.

Other papers in DATA STRUCTURES

Loading Question Papers

Fetching data from database...