0% found this document useful (0 votes)
10 views19 pages

Data Structures Exam Papers 2024

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)
10 views19 pages

Data Structures Exam Papers 2024

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

Enrolment No.

/Seat No_______________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE- SEMESTER–III (NEW) EXAMINATION – WINTER 2024
Subject Code: 3130702 Date: 26-11-2024
Subject Name: Data Structures
Time: 10:30 AM TO 01:00 PM Total Marks: 70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Simple and non-programmable scientific calculators are allowed.

Marks
Q.1 (a) Differentiate Primitive and Non Primitive Data Structures 03
(b) Derive basic operation of stack and write C function to implement it. 04
(c) Explain Row Major and Column Major with Example. 07

Q.2 (a) What is Sparse Matrix? 03


(b) Translate infix expression into its equivalent post fix expression: 04
A*(B+D)/E-F*(G+H/K)
(c) Write a program to implement Circular queue and show how it differ 07
from normal queue?
OR
(c) Explain the concept of Reverse Polish Notation (RPN) and describe the 07
process for evaluating an RPN expression using a stack. Provide a
detailed example of evaluating the following RPN expression: 5 1 2 + 4
*+3-

Q.3 (a) Write an algorithm for Bubble sort. 03


(b) Sort 20,35,40,100,3,10,15 using insertion sort. Show all passes. 04
(c) Compare and contrast Depth First Search (DFS) and Breadth First Search 07
(BFS) in terms of their algorithms, uses, and performance.
OR
Q.3 (a) Write an algorithm for Merge Sort. 03
(b) Sort the given values using Quick Sort? 65, 70, 75, 80, 85, 60, 55, 50, 45. 04
Show all passes.
(c) Describe the concept of hashing and explain different collision resolution 07
techniques, including separate chaining and open addressing. Illustrate
how each technique works with examples.

Q.4 (a) Define Graph and list any 3 uses of graph. 03


(b) How to prove array is sequential and contiguous? 04
(c) Explain the concept of a graph and its representations. Compare 07
adjacency matrix and adjacency list representations in terms of space
complexity and use cases.
OR
Q.4 (a) List any three uses of linked list. 03
1
(b) Write an algorithm to delete next element from doubly linked list from 04
given position,
(c) Write an algorithm to implement singly linked list and its operation such 07
as insert element at front, last and at any position.

Q.5 (a) What is priority queue? 03


(b) Write an algorithm to implement queue using Linked List. 04

(c) Explain the concept of a binary search tree (BST) and its properties. 07
Discuss how operations such as insertion, deletion, and searching are
performed in a BST.
OR
Q.5 (a) Define (1) Forest (2) Leaf Node (3) Tree 03
(b) Construct tree from Following 04
 In order Traversal: D, B, E, A, F, C
 Pre order Traversal: A, B, D, E, C, F
(c) Discuss the key concepts and techniques of AVL trees and 2-3 trees, 07
focusing on their balance mechanisms and the impact on performance.
Provide examples of insertions and deletions to illustrate how these trees
maintain balance.

***********

2
Enrolment No./Seat No_______________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER–III (NEW) EXAMINATION – SUMMER 2024
Subject Code:3130702 Date:19-07-2024
Subject Name: Data Structures
Time:10:30 AM TO 01:00 PM Total Marks:70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Simple and non-programmable scientific calculators are allowed.
MARKS

Q.1 (a) Explain data structure. Enlist and explain the importance of data structure. 03
(b) Define time and space complexity. Derive time complexity of merge sort. 04
(c) 1) Evaluate the postfix expression in tabular forms: 2 5 3 - * 8 / 4 + 03
2) Evaluate the prefix expression in tabular forms: / 7 * 1 + 4 – 6 3 04

Q.2 (a) Explain Tower of Hanoi with suitable example. 03


(b) Define hash function. Explain it with suitable example. 04
(c) Write an algorithm for the following stack operations. 07
1) PUSH 2) POP 3) DISPLAY
OR
(c) Write an algorithm for the following queue operations. 07
1) INSERT 2) DELETE 3) DISPLAY

Q.3 (a) Write an algorithm to add a node into a binary search tree. 03
(b) Explain Dequeue and Priority queue in detail. 04
(c) Construct the minimum spanning tree using prim’s algorithm for the 07
following graph.

OR
Q.3 (a) Write an algorithm to delete an item from the doubly linked list. 03
(b) Differentiate: BFS and DFS. 04
(c) Construct the minimum spanning tree using krushkal’s algorithm for the 07
following graph.
Q.4 (a) Define the terms below: 03
1) Threaded Tree 2) Acyclic graph 3) Sparse matrix
(b) Explain AVL tree in detail with suitable example. 04
(c) Construct a binary tree from the traversals given below: 07
Inorder : D, B, E, H, A, I, F, C, G
Preorder : A, B, D, E, H, C, F, I, G
OR
Q.4 (a) Define the terms below: 03
1) Complete Binary Tree 2) Forest 3) Abstract data type
(b) Explain 2-3 tree in brief. 04
(c) Write an algorithm to insert an item as below: 07
1) At the start of the linked list
2) At the end of the linked list

Q.5 (a) Define file. Explain its types. 03


(b) Explain bubble sort with suitable example. 04
(c) Build a chained hash table of 10 memory locations. Insert the keys 121, 3,4, 07
31, 61, 24, 7, 87, 8, 9 in hash table using chaining. Use h(k) = k mod m
(m=10).
OR
Q.5 (a) Define file organization. Explain different file organizations. 03
(b) Sort the following array elements using insertion sort algorithm. 04
8, -2, 5, 3, 9, 4, 6
(c) Explain Dijakstra’s shortest path using suitable example. 07

*************
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER–III (NEW) EXAMINATION – WINTER 2023
Subject Code:3130702 Date:16-01-2024
Subject Name:Data Structures
Time:10:30 AM TO 01:00 PM Total Marks:70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Simple and non-programmable scientific calculators are allowed.

MARKS

Q.1 (a) Define data structure. Enlist and explain types of data structure. 03
(b) Differentiate static and dynamic memory allocation. 04
(c) Convert the following infix expression into postfix expression using stack. 07
(A-B)/C*D^(E/F)^(G+H)

Q.2 (a) Compare array and linked list. 03


(b) Differentiate primitive and non-primitive data structures. 04
(c) Define stack. Write algorithms for PUSH, POP and PEEP operations of stack. 07
OR
(c) Define queue. Write algorithms for INSERT, DELETE and DISPLAY 07
operations of queue.

Q.3 (a) Enlist and explain any 3 applications of linked list. 03


(b) Design an algorithm to insert an element in doubly linked list. 04
(c) Do as directed:
i) Evaluate the postfix expression in tabular forms: 8 2 / 6 7 * + 03
ii) Explain Tower Of Hanoi with example. 04
OR
Q.3 (a) Enlist and explain any 3 applications of stack in computer science. 03
(b) Design an algorithm to delete an element in doubly linked list. 04
(c) Do as directed:
i) Evaluate the prefix expression in tabular forms: * / - 8 2 3 4 03
ii) Explain Sparse matrix with example. 04

Q.4 (a) Explain binary search tree with suitable example. 03


(b) Construct a binary tree from the traversals given below: 04
In-order : D, B, A, E, G, C, H, F, I
Pre-order : A, B, D, C, E, G, F, H, I
(c) Differentiate DFS and BFS in detail. 07
OR
Q.4 (a) Explain AVL tree with suitable example. 03
(b) Construct a binary tree from the traversals given below: 04
Pre-order : 1, 2, 4, 8, 9, 5, 3, 6, 7
Post-order : 8, 9, 4, 5, 2, 6, 7, 3, 1
(c) Explain prim’s and krushkal’s algorithm with suitable example. 07
Q.5 (a) State the reason why hash function is used. Give one example of hash function. 03
(b) Write a C program for bubble sort. 04

1
(c) Enlist and explain collision resolution techniques in hashing. 07
OR
Q.5 (a) Differentiate sequential search and binary search. 03
(b) Define file organization. Briefly summarize different file organizations. 04
(c) Do as directed below:
i) Sort following elements using quick sort. 05
10 15 28 09 40 35 29 12 06 07
ii) State time and space complexity of quick sort. 02

*************

2
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER–III(NEW) EXAMINATION – SUMMER 2023
Subject Code:3130702 Date:26-07-2023
Subject Name:Data Structures
Time:02:30 PM TO 05:00 PM Total Marks:70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Simple and non-programmable scientific calculators are allowed.

Q.1 (a) What is DS? Explain data structure and its types. 03
(b) Explain Tower of Hanoi with example. 04
(c) Write algorithms to insert, and delete elements in queue 07

Q.2 (a) Construct Binary Tree where the preorder traversal is 1,2,4,5,3,6,8,9,7 & 03
postorder is 4,5,2,8,9,6,7,3,1.
(b) Construct an AVL Tree by inserting numbers from 1 to 8. 04
(c) What is stack? Explain operations on stack in detail. 07
OR
(c) Explain tree traversal in detail with example. 07

Q.3 (a) Explain 2-3 Tree in brief. 03


(b) Explain any three hashing techniques with example. 04
(c) What is problem with simple queue? Explain its solution with example and 07
algorithms.
OR
Q.3 (a) Explain binary search technique. 03
(b) Explain fastest sorting technique with example. 04
(c) What is collision? Explain collision resolution techniques with example. 07

Q.4 (a) List all asymptotic notations and explain any one of it. 03
(b) List and explain linked list applications. 04
(c) What is doubly linked list? Write Algorithm for insertion and deletion in 07
doubly linked list.
OR
Q.4 (a) What is file? Explain types of files. 03
(b) Convert the following infix expressions to their prefix. 04
(A^B*C-D+E/F/(G+H))
(c) Explain Prim’s & Kruskal’s algorithm with suitable example 07

Q.5 (a) Explain malloc and free functions in ‘C’. 03


(b) Define the following: 1. Sibling 2. Forest 3. Complete Binary Tree 4. 04
Complete Graph
(c) Explain following: (i) Recursion (ii) Nonprimitive data structures (iii) 07
Hashing (iv) Non- linear data structures (v) sparse matrix (vi) Priority queue
(vii) Collision
OR
Q.5 (a) What is time complexity? Explain with example. 03
(b) Explain Binary Search with example. 04
(c) Write and explain algorithm for insertion in Singly Linked List 07

1
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER– III(NEW) EXAMINATION – WINTER 2022
Subject Code:3130702 Date:22-02-2023
Subject Name:Data Structures
Time:02:30 PM TO 05:00 PM Total Marks:70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Simple and non-programmable scientific calculators are allowed.

Q.1 (a) Differentiate primitive and non-primitive data structures 03


(b) Define time complexity? Explain worst case and best case complexity with 04
examples.
(c) Convert following infix expression into postfix expression using stack. 07
(A-B)/C*D^(E/F)^(G+H)

Q.2 (a) What is Sparse matrix? Write efficient vector representation of following 03
Sparse matrix.
1 0 0
0 2 0
0 0 3
(b) What is the worst case complexity of binary search? Write an algorithm for 04
binary search.
(c) Create Binary Search Tree for following Data and write pre-order traversal, in- 07
order traversal and post-order traversal of the constructed tree.
10 15 28 09 39 31 30 14 07 08
OR
(c) Create AVL tree for following Data and write pre-order traversal of the 07
constructed tree.
10 15 28 09 39 31 30 14 07 08
Q.3 (a) Write c program for bubble sort. 03
(b) Write algorithm to insert into simple queue and mention the limitation of 04
simple queue?
(c) Find the minimum spanning tree of following graph using Kruskal’s method. 07

OR
1
Q.3 (a) Write c program for selection sort. 03
(b) Write algorithm to delete from circular queue and mention the advantage of 04
circular queue over simple queue?
(c) Find the minimum spanning tree of the following graph using prim’s method. 07

Q.4 (a) What is priority queue? Is simple queue is anyhow priority queue? Explain 03
your answer.
(b) Write C program to find the Fibonacci sequence of n terms using recursion. 04
(c) Explain DFS and BFS with appropriate example. 07
OR
Q.4 (a) What is linked list? States the advantages of linked list over array. Also list 03
various types of the linked list.
(b) Write recursive solution for tower of Hanoi. How many moves require for 04
transferring three discs?
(c) Explain Dijkstra’s shortest path algorithm with appropriate example 07

Q.5 (a) Define following terms 03


1) Balance factor
2) Hash function
3) Cyclic graph
(b) Sort following data using merge sort. 04
10 15 28 09 39 31 30 14 07 08
(c) Define hash collision? Explain collision various resolution techniques. 07
OR
Q.5 (a) Define following terms 03
1) Hash table
2) Graph
3) Complete binary tree
(b) Sort following data using quick sort. 04
10 15 28 09 39 31 30 14 07 08
(c) What is file? Explain various types of file organization. 07

2
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER–III (NEW) EXAMINATION – WINTER 2021
Subject Code:3130702 Date:19-02-2022
Subject Name:Data Structures
Time:10:30 AM TO 01:00 PM Total Marks:70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Simple and non-programmable scientific calculators are allowed.

Q.1 (a) What is time complexity? Explain with example. 03


(b) Explain malloc and free functions in ‘C’. Also discuss advantages of 04
dynamic over static memory allocation.
(c) Explain following: 07
(i) priority queue (ii) primitive data structures (iii) non-primitive data
structures (iv) linear data structures (v) nonlinear data structures (vi)
applications of stack (vii) sparse matrix

Q.2 (a) Write an algorithm for infix to postfix conversion. 03


(b) Write an algorithm to evaluate postfix expression. Explain working of the 04
algorithm using appropriate example.
(c) Write a ‘C’ program to reverse a string using stack. 07
OR
(c) Write algorithm to (i) insert, and (ii) delete elements in circular queue. 07

Q.3 (a) Write user defined ‘C’ function to insert node at a specific location in singly 03
linked list.
(b) Write user defined ‘C’ function to delete node from end in circular linked 04
list.
(c) Write a ‘C’ program to implement queue using linked list. 07
OR
Q.3 (a) Write user defined ‘C’ function to insert node at the end in circular linked list. 03
(b) Write user defined ‘C’ function to delete node from a specific location in 04
doubly linked list.
(c) Write a ‘C’ program to implement stack using linked list. 07

Q.4 (a) Construct a binary tree from the traversals given below: 03
Inorder: D, B, A, E, G, C, H, F, I
Preorder: A, B, D, C, E, G, F, H, I
(b) Write a short on AVL tree. 04
(c) Explain the concept of B-tree with suitable example and list its applications. 07
OR
Q.4 (a) Construct a binary search tree from the following numbers. 03
38, 13, 51, 10, 12, 40, 84, 25, 89, 37, 66, 95
(b) Explain BFS and DFS. 04
(c) Explain B+ tree with example. 07

Q.5 (a) Explain Prim’s algorithm. 03


(b) Write a ‘C’ program for selection sort. 04
(c) List out different hash methods and explain any three. 07
1
OR
Q.5 (a) Define terms with respect to file: fields, records, database 03
(b) Compare sequential and binary search methods. 04
(c) Apply quick sort for the following data: 07
9, 7, 5, 11, 12, 2, 14, 3, 10, 6

**********

2
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER–III (NEW) EXAMINATION – SUMMER 2021
Subject Code:3130702 Date:08/09/2021
Subject Name:Data Structures
Time:10:30 AM TO 01:00 PM Total Marks:70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
4. Simple and non-programmable scientific calculators are allowed.

Q.1 (a) Explain primitive and Non-primitive data types in detail. 03


(b) Explain Binary Search with example. 04
(c) Explain Asymptotic Notations in detail. 07
Q.2 (a) Differentiate: Static and Dynamic Memory Allocation 03
(b) Explain linear and Non-linear data structure with example. 04
(c) What is stack? Explain operations on stack in detail. 07
OR
(c) What is queue? Explain operations on queue in detail. 07
Q.3 (a) Explain advantages of circular queue over Simple queue. 03
(b) Explain Tower Of Hanoi with example. 04
(c) Write and explain algorithm for deletion in Singly Linked List. 07
OR
Q.3 (a) Evaluate the following postfix expression in tabular form: 3 5 * 6 2 / 03
+
(b) Explain Dequeue and Priority queue in detail. 04
(c) Write and Explain algorithm for insertion in doubly linked list. 07
Q.4 (a) Define the following: 03
1. Sibling
2. Forest
3. Strictly Binary Tree
(b) Construct BST for following sequence and find inorder traversal for 04
the same.
35, 46, 29, 2, 24 ,68, 44, 57, 1, 22, 79, 71
(c) Explain Prim’s algorithm with suitable example. 07
OR
Q.4 (a) Write an algorithm for selection sort. 03
(b) Differentitae: BFS and DFS. 04
(c) Explain Kruskal’s algorithm with suitable example. 07
Q.5 (a) Explain indexed file organization. 03
(b) Explain rotation rules for AVL tree. 04
(c) Explain insertion and deletion in B-tree with example. 07
OR
Q.5 (a) Explain random file organization. 03
(b) Explain collision resolution techniques with example. 04
(c) Construct AVL tree for following sequence: 07
10, 20, 30, 40, 50, 60, 70 ,80
*************

1
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE- SEMESTER–III (NEW) EXAMINATION – WINTER 2020
Subject Code:3130702 Date:10/03/2021
Subject Name:Data Structures
Time:10:30 AM TO 12:30 PM Total Marks:56
Instructions:
1. Attempt any FOUR questions out of EIGHT questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.

Marks
Q.1 (a) Compare array and linked list. 03
(b) Compare primitive and non primitive data types. datastructures 04
(c) Write an algorithm to perform insert and delete operations on simple queue. 07

Q.2 (a) Search the number 50 from the given data using binary search technique. 03
Illustrate the searching process.
10, 14, 20, 39, 41, 45, 49, 50, 60
(b) Apply merge sort algorithm to the following elements. 20, 10, 5, 15, 25, 30, 04
50, 35
(c) Write a ‘C’ program for bubble sort. 07

Q.3 (a) What is stack? Why do we use multiple stacks? 03


(b) Convert the following infix expressions to their prefix and postfix 04
equivalents.
1. A*B+C/D
2. (A*B)+(C/D)-(D+E)
(c) What is priority queue? Discuss its applications and implementation details. 07

Q.4 (a) Evaluate the following postfix expression using stack. 03


53+62/*35*+
(b) Design an algorithm to perform insert operation in circular queue. 04
(c) Design an algorithm to merge two linked list. 07

Q.5 (a) Define: 1. Acyclic graph 2. Leaf node 3. Complete binary tree 03
(b) For following expressions, construct the corresponding binary tree. 04
1. A+B/C*D-E
2. ((A+B)-(C*D))%((E^F)/(G-H))
(c) How are graphs represented inside a computer’s memory? Which method 07
do you prefer and why?

Q.6 (a) Define: 1. Connected graph 2. Threaded tree 3. Degree of node 03


(b) Differentiate between depth first search and breadth first search. 04
(c) Design an algorithm to insert a given value in the binary search tree. 07

Q.7 (a) Explain basic file operations. 03


(b) List out applications of hashing. 04
(c) What is file organization? Briefly summarize different file organizations. 07

1
Q.8 (a) Give a brief note on indexing. 03
(b) Build a chained hash table of 10 memory locations. Insert the keys 131, 3, 04
4, 21, 61, 24, 7, 97, 8, 9 in hash table using chaining. Use h(k) = k mod m.
(m=10)
(c) Consider the hash table of size 10. Using quadratic probing, insert the keys 07
72, 27, 36, 24, 63, 81, and 101 into hash table. Take c1=1 and c2=3.

**********************

2
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER– III EXAMINATION – SUMMER 2020
Subject Code: 3130702 Date:27/10/2020
Subject Name: Data Structures
Time: 02:30 PM TO 05:00 PM Total Marks: 70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.

Marks

Q.1 (a) Differentiate between data types and data structures. 03


(b) Answer the followings: 04
(1) Give examples of Linear and Non-Linear
Data Structures.
(2) What do you mean by Abstract Data Types?

(c) Discuss and write a program to implement queue 07


functions using arrays.

Q.2 (a) Distinguish between stack and queue. 03


(b) What is top of stack? Why stack is called LIFO list? 04
(c) What is a circular queue? How do you check the 07
queue full condition? Write an algorithm to count
the nodes in a circular queue.
OR
(c) Explain creation, insertion and deletion of doubly 07
linked list with example.
Q.3 (a) What are binary trees? Mention different types of 03
binary trees with example.
(b) What is a graph? Explain various representations of 04
graphs.
(c) Write an algorithm to add a node into a binary 07
search tree.
OR
Q.3 (a) What is B -tree of order m? Draw a B-tree of order 03
3.
(b) Construct a binary tree having the following 04
traversal sequences:
Preorder traversal A B C D E F G H I
Inorder traversal B C A E D G H F I
(c) Discuss algorithm of Breadth First Search (BFS) 07
traversal for a Graph. Explain with an example.
Q.4 (a) Explain Sequential file organizations and list its 03
advantages and disadvantages.
(b) How access of record is performed in multi key file 04
organization?
1
(c) Describe various collision resolution techniques in 07
hashing.
OR
Q.4 (a) Explain indexed sequential file structure. 03
(b) Explain minimal spanning tree. 04
(c) What is hashing? What are the qualities of a good 07
hash function? Explain any two hash functions in
detail.
Q.5 (a) Define topological sort? 03
(b) Compare sequential searching with binary 04
searching in detail.
(c) Examine the algorithm for Insertion sort and sort the 07
following array: 77, 33, 44, 11, 88, 22, 66, 55
OR

Q.5 (a) What do you mean by internal and external sorting? 03


(b) Write an algorithm for quick sort. 04
(c) What is Binary Search Tree? Construct a binary 07
search tree for the following elements
21, 16, 24, 18, 22, 25, 26, 27, 29, 33

2
Seat No.: ________ Enrolment No.___________

GUJARAT TECHNOLOGICAL UNIVERSITY


BE - SEMESTER– III (New) EXAMINATION – WINTER 2019
Subject Code: 3130702 Date: 28/11/2019
Subject Name: Data Structures
Time: 02:30 PM TO 05:00 PM Total Marks: 70
Instructions:
1. Attempt all questions.
2. Make suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.

Marks
Q.1 (a) Discuss various types of data structures with 03
example.
(b) What is hash function used for? Give one example 04
of a hash function.
(c) What is time and space analysis? State and explain 07
time analysis for linear search and binary search
method.

Q.2 (a) Compare Array and Link list. 03


(b) State disadvantages of simple queue. How to 04
overcome it?
(c) Write an algorithm for INSERT, DELETE and 07
DISPLAY function of Circular Queue.
OR
(c) Write an algorithm for INSERT operation to insert 07
a node at a given position in a Link list.
Q.3 (a) Discuss height balance tree. 03
(b) Discuss Minimal Spanning Tree. 04
(c) Write a recursive function to compute factorial of 07
a number. Show usage of STACK in recursion for
this function.
OR
Q.3 (a) Write an algorithm to find length of a simple link 03
list.
(b) Write an algorithm to insert a node in a Circular 04
Link List at the FIRST position.
(c) Write an algorithm for DELETE operation in a 07
Binary search tree.
Q.4 (a) Discuss Threaded Binary Tree. 03
(b) Write an algorithm for a non recursive (Iterative) 04
pre order traversal of Binary search tree.
(c) Create an AVL tree for the following sequence of 07
numbers. Also mention name of action taken.
200, 400, 800, 900, 850, 700, 950, 100, 150
OR

Q.4 (a) Define following with respect to Tree: 03


i) M-ary tree ii) Out Degree iii) Leaf
(b) State at least one efficient representation of a 04
sparse matrix.
1
(c) Discuss algorithm of Breadth First Search (BFS) 07
traversal for a Graph. Explain with an example.
Q.5 (a) Write algorithm for Bubble sort method. 03
(b) Write algorithm for Merge sort method. 04
(c) Explain Sequential Files and Indexed Sequential 07
Files Structures
OR
Q.5 (a) Create 2-3 Tree for the following sequence: 03
50, 100, 150, 200
(b) Represent following in form of an expression tree: 04
A+B*(C+D)
(c) State and explain collision resolution techniques in 07
hashing.

****************

You might also like