0% found this document useful (0 votes)
18 views2 pages

DSA w22

Uploaded by

arjunssagar3
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)
18 views2 pages

DSA w22

Uploaded by

arjunssagar3
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
You are on page 1/ 2

B.E.

Computer Science & Engineering (MODEL CURRICULUM) Sem-III


SE102CS : Data Structure & Algorithms

P. Pages : 2 GUG/W/22/13802
Time : Three Hours *3031*
Max. Marks : 80
_____________________________________________________________________
Notes : 1. All questions carry equal marks.
2. Assume suitable data wherever necessary.
3. Illustrate your answers wherever necessary with the help of neat sketches.

1. a) What is Data Structure? Explain its types by giving example. 8

b) Write a function for linear search and binary search. Also explain its worst case and best 8
case time complexity?

OR
2. a) Define time and space complexity of algorithm? Explain different asymptotic notations 8
used for analysis of algorithm.

b) Explain data structure operations with the help of example? 8

3. a) Write a program in ‘C’ to count number of nodes in a singly linked list? 8

b) Explain circular linked list and doubly linked list with neat sketch. 8

OR
4. a) What is linked list? Explain various types of linked list with neat sketch. 8

b) Write a C program to implement singly linked list. 8

5. a) Convert the following Infix to postfix expression. 8


i) ( A + B) − C + D  ( E / F  G )
ii) ( x + y )  z   ( a − b ) / c + e 
iii) ( A + B ) / C − D  ( F − Q )  + G
iv) ( A  B  C) / D  E  ( G  F)
b) Explain push and pop function for stack. Write applications of stack. 8

OR
6. a) Write short note on priority queue? 4

b) Convert following infix expression to prefix. 4


i) ( A + B  D ) / ( E − F) + G
ii) A  ( B + D) / E − F  ( G + H / K )

c) Write a C program for insertion, deletion operation in a linear queue? 8

GUG/W/22/13802 1 P.T.O
7. a) Define Binary trees. Write a C – function for preorder, postorder, inorder tree traversals. 8
Also write the preorder, postorder, inorder expression for the following binary tree.
A

B C

D
E F

G
b) Write short note on AVL trees. Explain single rotation and double rotation in AVL trees. 8

OR
8. a) What is binary search tree? Write a function for insert, delete and search operation in 8
BST?

b) Explain the following tree terminologies. 8


i) Balance factor
ii) Path
iii) Degree
iv) Depth

9. a) Write a recursive C – program to implement quick sort? 8

b) Sort the following array using bubble sort, slowing all the iterations – 11, 15, 2, 13, 6, 8 8
Also write function for bubble sort.

OR
10. a) Explain Prim’s and Kruskal’s spanning tree algorithms with example? 8

b) Define the following. 8


i) Graph
ii) Directed Graph
iii) Degree of Graph
iv) Complete Graph

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

GUG/W/22/13802 2

You might also like