100% found this document useful (1 vote)
107 views2 pages

Sample Viva Questions of DSA LAB

The document contains a list of 52 sample interview questions related to data structures and algorithms topics like stacks, queues, linked lists, trees, graphs, and their implementations and applications. Some example questions are about defining common data structures like stacks, queues and their operations, comparing linear and non-linear data structures, tree traversals and properties of binary search trees and AVL trees.

Uploaded by

shubham dhabarde
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
100% found this document useful (1 vote)
107 views2 pages

Sample Viva Questions of DSA LAB

The document contains a list of 52 sample interview questions related to data structures and algorithms topics like stacks, queues, linked lists, trees, graphs, and their implementations and applications. Some example questions are about defining common data structures like stacks, queues and their operations, comparing linear and non-linear data structures, tree traversals and properties of binary search trees and AVL trees.

Uploaded by

shubham dhabarde
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

Sample Viva Questions of DSA LAB

1. What are Data Structures?


2. Why Create Data Structures?
3. What are some applications of Data structures?
4. Describe the types of Data Structures?
5. Can you tell how linear data structures differ from non-linear data structures?
6. What is a stack? What are the applications of stack?
7. What are different operations available in stack data structure?
8. What is the time complexity of Algorithm?
9. What is Recursion ?
10. What is a queue? What are the applications of queue?
11. What are different operations available in queue data structure?
12. How is a stack different from a queue?
13. Explain the process behind storing a variable in memory.
14. What is a priority queue?
15. The data structure required for Breadth First Traversal on a graph is
16. A queue follows : LIFo or FIFO
17. If max_size is size of array used in implementation of circular queue.how is rear manipulated
while inserting an element
18. Explain ENQUEUE and DEQUEUE operations
19. A _____ is a linear list in which insertions and deletions are made to form either end of the
structure
20. What kind of data structure does a queue is
21. In a queue,the initial values of front pointer f rare pointer r should be ____ and ____
respectively
22. A varient of linked list in which last node of the list points to the first node of the list is
23. A varient of the linked list in which none of the node contains NULL pointer
24. In circular linked list insertion of node requires modification of how many pointers
25. What is the time complexity to count the number of elements in the linked list
26. to find out maximum elements in a list of n numbers one needs at least _____ number of
comparisons
27. Linked List is generally considered as an example of ___ type of memory allocation
28. What is a memory efficient double linked list?
29. How are linked lists more efficient than arrays?
30. What is the maximum number of nodes in a binary tree of height k?
31. What are tree traversals?
32. Types of tree traversals,explain it also
33. What is a Binary Search Tree?
34. What is an AVL Tree? And what is balance factor
35. What is a full binary tree?
36. How many distinct binary search trees can be created out of 4 distinct keys?
37. Which of the following traversal outputs the data in sorted order in a BST?
38. Which of the following traversals is sufficient to construct BST from given traversals 1) Inorder 2)
Preorder 3) Postorder
39. Which of the following is not a height balanced tree-Binary Search tree,AVL Tree,Splay
Tree,Binary Heap Tree
40. What is the maximum height of any AVL-tree with 7 nodes? Assume that the height of a tree
with a single node is 0.
41. In a full binary tree, every internal node has exactly two children. A full binary tree with 2n+1
nodes contains ----- internal nodes
42. A binary search tree is generated by inserting in order the following integers:
43. 50, 15, 62, 5, 20, 58, 91, 3, 8, 37, 60, 24, The number of the node in the left sub-tree and right
sub-tree of the root, respectively, is
44. Which of the following tree traversal visits root node last
45. What are red-black trees? What problem do they solve
46. What are the characteristics of red-black trees?
47. What are the rules that have to be followed when an item is inserted or deleted from a red
black tree?
48. What is Segment Tree ?
49. advantage of adjacency list representation over adjacency matrix representation of a graph?
50. What are the appropriate data structures for following algorithms?
1) Breadth First Search
2) Depth First Search
51. What is the difference between the Breadth First Search (BFS) and Depth First Search (DFS)?

You might also like