Subject
AJ - 2160707
DS - 2130702
DBMS - 2130703
OS - 2140702
SE - 2160701
TOC - 2160704
About
About Us
Contact Us
Paper Solution of
DS
(2130702)
for
Summer
- 2019
Data-Structure-2130702
Summer-2019
Modal title
Widget settings form goes here
GUJARAT TECHNOLOGICAL UNIVERSITY
BE - Semester - ____ EXAMINATION -
Summer-2019
Date:
06/04/2019
Total Marks :
70
NOTE:
Click on the Question to View Answer!
Q.1
(a)
Define Data Structure and differentiate between linear and nonlinear data structures
3 marks
(b)
Write a pseudocode for PUSH and POP operations of stack
4 marks
(c)
Write algorithm for inserting an element in circular queue and deleting a node from a singly linked list.
7 marks
Q.2
(a)
Illustrate the working of priority queue with suitable example.
3 marks
(b)
Write recursive algorithm to compute factorial of a given number. Which data structure can be used to implement this algorithm?
4 marks
(c)
Sort the following numbers in ascending order by applying quick sort.
29 15 11 82 22 17 53 57 4 8
7 marks
OR
(c)
“If no interchanges occurred, then all the elements must be sorted and no further passes are required.” Which sorting technique works on this principal? Apply the same sorting technique on the following data to sort them in ascending order.
11, 15, 13, 14, 2, 8, 10
7 marks
Q.3
(a)
Evaluate the following postfix expression in tabular form showing stack after every step. 7 6 + 4 * 4 10 + - 5 +
3 marks
(b)
Write the algorithm for binary search.
3 marks
(c)
Explain the working of the Prim’s algorithm with suitable example.
7 marks
OR
(a)
List the advantages of a doubly linked list over singly linked list.
3 marks
(b)
List out graph traversal techniques & explain any one using suitable example.
4 marks
(c)
Apply Djkstra’s algorithm on following graph with Node A as the starting node.
7 marks
Q.4
(a)
Explain Sequential search method with suitable example.
3 marks
(b)
Given Inorder and Preorder traversal, find Postorder traversal.
Inorder:
Y B K C F A G X E D H Z
Preorder:
G B Y A C K F X D E Z H
4 marks
(c)
Explain collision in the context of hashing? Discuss collision resolution techniques.
7 marks
OR
(a)
Explain indexing structure for index files.
3 marks
(b)
Draw a Binary expression tree for the following and perform preorder traversal:
a * ( b + c ) + ( d * e ) / f + g * h
4 marks
(c)
Explain insert and delete operations in AVL trees with suitable examples.
7 marks
Q.5
(a)
Define: i) Cyclic Graph ii) Siblings iii) Strictly Binary Tree
3 marks
(b)
Explain Threaded binary trees with suitable examples.
4 marks
(c)
Write a C program to reverse a string using stack.
7 marks
OR
(a)
Explain Sequential file organizations and list its advantages and disadvantages.
3 marks
(b)
Write an algorithm for insertion sort.
4 marks
(c)
Discuss different representations of a graph.
7 marks