PYQ – DATA STRUCTURES AND ALGORITHM (2418301) | SEMESTER 3RD (2ND YEAR) | Year 2024

Share:WhatsAppTelegram
Question 1

Data Structure & Algorithm 2024 NEW PYQ.


Group A

 

Choose the most suitable answer from the following options: -  (2*10=20)


(i) The operation of inserting an element into a stack is called _______.

(a) Peep

(b) Enqueue

(c) Push  

(d) Pop


(ii) A binary search tree (BST) can have duplicate elements.

(a) True

(b) False 


(iii) Match the following algorithm with their time complexities:

 


Algorithm

Time Complexity

Bubble Sort

O (n log n)

Quick Sort

O (log n)

Binary Sort

O (n)

Linear Sort

O (n ^2)


(iv) Which of the following is a data structure?

(a) Tree

(b) Graph

(c) Queue

(d) Hash Table


(v) Which data structure follows the Last In First Out (LIFO) principle?

(a) Queue

(b) Stack

(c) Linked list

(d) Array


(vi) What is the time complexity of merge sort in the worst case?

(a) O (n)

(b) O (n^2)

(c) O (n log n)

(d) O (log n)


(vii) In a binary search tree. The left child of a node contains a value _______ the node’s value.

(a) Less then

(b) Greater than

(c) Equal to

(d) Not related to


(viii) Which of the following sorting algorithms is considered stable?

(a) Quick Sort

(b) Merge Sort

(c) Heap Sort

(d) Selection Sort


(ix) Which data structure is used in the implementation of recursion?

(a) Queue

(b) Array

(c) Stack

(d) Graph

 
(x) In a graph, what is the term used to describe a sequence of edges that connect a pair of vertices?

(a) Degree

(b) Path

(c) Cycle

(d) Loop

Group:-"B"

➥ Answer all Five Questions: -                         (5*4=20) 

 

2. Differentiate between linear and non-linear data structures.

OR

Differentiate between time and space complexity with example.

 

3. Explain the need for data structures in programming. 

OR

Discuss advantages of using linked lists over arrays?

 

4. Differentiate between a stack and a queue. 

OR

Differentiate between a singly linked list and a doubly linked list?

 

5. Define a tree and its basic terminology. 

OR

Describe the different types of binary trees.

 

6. Explain the adjacency matrix representation of a graph.  

OR

Define a graph and its basic terminology.

 

Group:- "C"

➥ Answer all Five Questions: -                         (5*6=30) 

 

7. Explain the working principle of the binary search algorithm. Compare its efficiency with linear search in terms of time complexity. 

OR

Describe the structure and operations of a doubly linked list.

 

8. Discuss the properties and operations of a binary search tree (BST). Explain how insertion, deletion, and searching are performed in a BST. 

OR

Explain the depth-first search (DFS) and breadth-first search (BFS) algorithms for graph traversal.

 

9. Describe the concept and applications of an AVL tree. How does it differ from a standard binary search tree?  

OR

Explain the use of a stack in infix to postfix conversion? List other applications of stack.

 

10. Explain the concept of a double-ended queue (deque). Explain enqueue and dequeue operations in queue.  

OR

List various sorting algorithms. Explain Bubble sort with example.

 

11. Explain Quick Sort with example.  

OR

Explain a circular linked list. How dose memory is utilized in Circular linked list.

 

 

 

*****

Q1
Question 2

Data Structure & Algorithm 2024 OLD PYQ.


Group A

 

Choose the most suitable answer from the following options: -  (2*10=20)


(i) Data Structure is a  

(a) A programming language

(b) A collection of algorithms

(c) A way to store and organize data

(d) A type of computer hardware


(ii) The prefix form of A-B/ (C * D ^ E) is

(a) -A/B*C^DE

(b) -A/BC*^DE

(c) -ABCD*^DE

(d) -/*^ACBDE


(iii) Match the following:

(a) Linked list

(b) Tree

(c) non-linear data structure

(d) Linear data structure


(iv) The situation when in a linked list START =NULL is-----------

(a) Underflow

(b) Overflow

(c) Houseful

(d) Saturated


(v) If the elements ‘1’ ‘2’ ‘3’ and ‘4’ are added in a stack, so the order of removal would be---------

(a) 1234

(b) 2134

(c) 4321

(d) None of the These


(vi) A graph is a tree if and only if graph is -----------

(a) Directed graph

(b) Contains no cycles

(c) planar

(d) Completely connected


(vii) Which of the following is the correct way of declaring an array?

(a) int javatpoint[10];

(b) int javatpoint;

(c) javatpoint{20};

(d)array javatpoint[10]


(viii) Which of the following is the disadvantage of the array?

(a) Stack and Queue can be implemented through an array

(b) Index of the first element in an array can be negative

(c) Wastage of memory if the elements inserted in an array are lesser than the allocated size

(d) Elements can be accessed sequentially.


(ix) The data structure required for Breadth First Traversal on a graph is --------

(a) Array

(b) Stack

(c) Tree

(d) Queue

 
(x) Binary search is always faster than linear search.

(a) True

(b) False

 

Group:-"B"

➥ Answer all Five Questions: -                         (5*4=20) 

 

2. Explain time complexity and space complexity of algorithm.

OR

Explain Complete binary tree.

 

3. Define Stack and its operation 

OR

Explain infix, prefix and postfix operation with example.

 

4. Differentiate between linear and non-line data structure. 

OR

Define Queue data structure and its operation.

 

5. List terminologies associated in tree data structure.

                                                                              OR

Discuss any four applications of stack.

 

6. Write formula to calculate address of an element in two dimensional and three-dimensional array.

OR

Discuss the advantage and disadvantages of circular linked list.

 

Group:- "C"

➥ Answer all Five Questions: -                         (5*6=30) 

 

7. Explain doubly linked list in details. List the advantage of doubly linked list over singly linked list.

OR

Write an algorithm to implement insertion sort with suitable example.

 

8. Explain operations of DFS and BSF in detail with example.  

OR

Explain different type of queue in detail.

 

9. Write algorithm to delete a node from the beginning of linked list.  

OR

Explain Binary Search Tree. Explain insertion of a node in binary search tree.

 

10. Explain two-dimensional array. How two-dimensional array can be represented in memory?  

OR

Explain quick sort. Sort the given values using quick sort-38,81,22,48,13,69,93,14,45,58,79,72

 

11. Discuss Binary search in detail with steps involved.  

OR

Write short notes on: -

(a) Bubble Sort   

(b) Graph Representation Method

 

 

*****

Q2

PYQ Video References

No references available right now.

Comments & Reviews

Loading comments...