JNTU
JNTU MCA 2017 DATA STRUCTURES AND ALGORITHMS Previous Question Paper (August - 2017 - R15)
Note: This question paper contains two parts A and B. Part A is compulsory which carries 25 marks. Answer all questions in Part A. Part B consists of 5 Units. Answer any one full question from each unit. Each question carries 10 marks and may have a, b, c as sub questions.
Part A
5 × 5 Marks = 25
Describe recursion implementation on Stack.
Answer
Recursion is implemented using a System Stack. When a function calls itself, the current execution state, including local variables, parameters, and the return address, is pushed onto the stack as a Stack Frame. Each recursive call creates a new frame, allowing the program to maintain the state of each active call. Once the base case is reached, the stack frames are popped in reverse order (Last-In, First-Out), restoring the previous state and returning control to the caller until the initial function call completes.
Differentiate between tree and graph with an example.
Answer
A Tree is a hierarchical data structure with a single root node where each node has at most one parent, and there are no cycles. A Graph is a non-linear structure consisting of vertices connected by edges, which can contain cycles and does not require a root or hierarchical structure.
For example, a file system directory structure is a tree, whereas a social network map where users are connected to multiple friends is a graph.
What is folding? Explain with example.
Answer
Sign in to view the complete answer paper.
What is B Tree order of m? Discuss briefly.
Answer
Sign in to view the complete answer paper.
What is Greedy Method? Explain Briefly.
Answer
Sign in to view the complete answer paper.
Part B
5 × 10 Marks = 50
Explain the following operations in Singly Linked List
Insert a node at end of the list
Answer
Sign in to view the complete answer paper.
Delete a node from middle of the list.
Answer
Sign in to view the complete answer paper.
Explain the operations on Circular Queue with suitable example.
Answer
Sign in to view the complete answer paper.
Explain DFS Graph Traversal algorithm with example.
Answer
Sign in to view the complete answer paper.
Describe about Fibonacci Heaps with example.
Answer
Sign in to view the complete answer paper.
Explain Radix Sort with following example: 10, 21, 17, 34, 44, 11, 654, 123
Answer
Sign in to view the complete answer paper.
What is quick sort? Explain with following example: 26, 5, 37, 1, 61, 11, 59, 15, 48, 19
Answer
Sign in to view the complete answer paper.
With an example explain the Insertion Operation of AVL tree.
Answer
Sign in to view the complete answer paper.
Construct a B Tree an order 5 with following example: 1, 12, 8, 2, 25, 6, 14, 28, 17, 7, 52, 16, 48, 68, 3, 26, 29, 53, 55, 45.
Answer
Sign in to view the complete answer paper.
Consider a set given jobs as (j1, j2, j3, j4, j5) with deadlines and profits (2, 1, 3, 2, 1) and profits (60, 100, 20, 40, 20). Find a sequence of jobs which will be completed within their deadlines and will give the maximum profit.
Answer
Sign in to view the complete answer paper.
Discuss about Single Source Shortest Path algorithm with suitable example.
Answer
Sign in to view the complete answer paper.