You are on page 1of 2

JAIPUR ENGINEERING COLLEGE AND RESEARCH CENTRE

Department of Computer Science & Engineering


SUBJECT: Data Structure and Algorithm
Question Bank

1. Apply binary search to find 123 in a list.


49,98,101,123,149,194,199,211,240,286,840,930 (12 data)
2. Write an algorithm to delete a data key from a Threaded binary tree.
3. In Djikstra’s shortest path algorithm, what technique is used to choose the next vertex to
process?
4. Suppose the following values are inserted into a binary tree, in the order given:
12,7,9,10,22,24,30,18,3,14,20
Draw a diagram of the resulting binary tree.
5. what is insertion sort? How many passes are required for the elements to be sorted ?
6. Is there any difference between threaded and unthreaded binary tree? What is B tree?
Explain.
7. Demonstrate Threaded Binary Tree.
8. Mention some methods for choosing the pivot element in quick sort?
9. Define a) Insertion Sort b) Selection Sort c) Quick Sort d) Radix Sort e) Merge Sort
10. Insert the following data keys in an AVL tree.
16,23,9,163,64,29,73,83,90,96 (10 keys)
11. Compare Binary Search and Sequential Search.
12. What is the main idea behind the selection sort?
13. Convert (a+(b*(c-d)+(e)-(f*g))) into postfix notation.
14. Define the concept of balanced tree. Write pseudo code for insertion and deletion from
AVL tree.
15. Define searching
16. Design Binary Search Tree with some example.
17. Differentiate between Tree and Graph.
18. Define the following binary tree.
i) Complete binary tree
ii) Strictly binary tree
19. By taking suitable example explain the principle of operation of Heap Sort.
20. Identify the property of Spanning Tree.
21. Elaborate Graph and its representation using adjacency matrix.
22. Illustrate Counting Sort algorithm with suitable example.
23. Use Prim’s algorithm and Kruskal’s algorithm to find minimum spanning tree for following
graph
24. Write short note on
DFS Traversal Algorithm
BFS Traversal Algorithm
25. Suppose the following sequence list of nodes of Binary tree T in preorder and inorder
respectively.
Preorder: G,B,Q,A,C,K,F,P,D,E,R,H
Inorder: Q,B,K,C,F,A,G,P,E,D,H,R
26. Insert the following list of elements in AVL tree. 3,5,11,8,4,1,12,7,2,6,10
27. Illustrate ways to represent a Graph.
28. Sort the following data in ascending order using Quick Sort 9,4,12,6,5,10,7
29. Name the Data Structure used in BFS and DFS of a graph.
30. A hash table contains 10 buckets and uses linear probing to resolve collisions. The key values are
integers and the hash function used is key % 10. If the values 43, 165, 62, 123, 142 are inserted in
the table, in what location would the key value 142 be inserted? (GATE CSE 2005)
31. Write the advantage of chained hash table (external hashing) over the open addressing scheme.
(GATE CSE 1996)

You might also like