0% found this document useful (0 votes)
32 views

Data Structure Assignment

The document discusses several data structures and algorithms topics including: 1) Determining the asymptotic tight bound of the function f(n)=7n^2+5n is O(n^2). 2) The operations on a queue are described, with the final front and rear positions provided for straight and circular queues. 3) Converting an infix expression to postfix and prefix forms, then evaluating the postfix expression is demonstrated.

Uploaded by

BIPRONIL GHOSH
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
32 views

Data Structure Assignment

The document discusses several data structures and algorithms topics including: 1) Determining the asymptotic tight bound of the function f(n)=7n^2+5n is O(n^2). 2) The operations on a queue are described, with the final front and rear positions provided for straight and circular queues. 3) Converting an infix expression to postfix and prefix forms, then evaluating the postfix expression is demonstrated.

Uploaded by

BIPRONIL GHOSH
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 3

data structure, efficiency of an algorithm, abstract data type (ADT)

Determine asymptotic tight bound for the function f(n)=7n2+5n

front=3, rear=5
Queue=_ ,_ ,2, 4 ,5 ,_,_,_ ( _ states for empty cell)
 6 is added
 Two elements are deleted
 10 and 12 added
 Two elements are deleted
 2 and 3 are added.
final value of front and rear for the following operation for straight queue and circular Q

Infix to Postfix/Prefix conversion and evaluate value


((((a+b) / c) * d) / (e + f * g)) - (h / i - j)
a=10, b=8, c=3, d=4, e=2, f=1, g=6, h=55, i=11, j=5

STACK Vs QUEUE
String reverse –explain with example

B-tree of order 3 with the following value


16, 20, 22, 42, 12, 30, 32, 18, 10, 34, 36, 38, 14, 24, 28, 40, 26.

Threaded binary tree, ,AVL tree


expression tree of the following expression.
((x + y) + z / (p - q)+ r )* (a + b)

binary tree from the following information:

In-order: 50, 10, 30, 90, 60, 80, 40, 20, 70

Pre-order: 60, 10, 50, 90, 30, 40, 80, 70, 20

What is the post order traversal of this tree?

limitation of linear queue? How can it solved. Explain with diagram.

Construct an AVL tree mentioning


12, 11, 13, 10, 9, 15, 14, 18, 7, 6, 5, 22, 20, 9 and 4.
In details

2- dimensional array, sparse matrix Multiple Stack, polynomials, Double Linked List

Write an Algorithm for deletion from the rear end of the Deque.

Consider a 2D array arr[20][20] having base address 2000 and no. of bytes per element is
compute the address of arr[9][15] in row major and column major order.

Write an algorithm to insert a data element after a particular data element in a singly linked list.
Insert the following numbers in an empty BST:
40, 25, 70, 22, 35, 60, 80, 90, 10, 30.

Draw the tree and perform the following operations (not successively)

i) Delete 30 ii) Delete 80 iii) Delete 40

Compare and contrast between


Binary tree Vs Binary Search tree
B tree Vs B+ tree

Kruskal’s algorithm- minimum spanning tree of the following graph

BFS and DFS following graph:


Short note:

Recursion Vs Iteration
Row-Major and Column-Major ordering
Time complexity of Quick Sort and Merge Sort
Insertion Sort
Internal and external sorting
Different collision resolution techniques of hashing
Red/Black tree
Representation of Graph

You might also like