Data Structure Interview Question and Answers
6. |
Define complete binary tree? |
|
- A binary tree in which every non leaf node has exactly two children not necessarily on the same level.
-
It is also called as strictly binary tree.
|
|
|
7. |
What is Binary Search Tree? |
|
The property that makes a binary tree into a binary search tree is that for every node, x in the tree, the values of all the keys in its left sub tree are smaller than the key value in x, and the values of all the keys in its right sub tree are larger than the key value in x. |
`
|
|
8. |
What is called collections? |
|
- The principal benefit of collection is that they standardize the way groups of objects are handled by the programs.
- All collections are designed around a set of clearly defined interfaces.
|
|
|
9. |
What are the applications of Stack? |
|
- Infix to post fix conversion
- Expression evaluation
- Function calls
- Tower of Hanoi
|
|
|
10. |
What are the applications of queue? |
|
- Job scheduling
- Computer networks
|
|
|