Define depth and height of a node?



Define depth and height of a node?..

Answer / Arvind Kumar Gautam

The depth of a node in a tree is the number of edges between it and the root node. The height of a node is the number of edges from that node to the farthest leaf node in the subtree rooted at that node.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Data Structures Interview Questions

What happens if we put a key object in a hashmap which exists?

1 Answers  


Is quicksort a stable sorting algorithm?

1 Answers  


What do you mean by the term “percolate up”?

1 Answers  


What exactly is a thread?

1 Answers  


What do you mean by union-by-weight?

1 Answers  


Differentiate between list and set.

1 Answers  


simple algorithm for bubble sort?

1 Answers  


What is frozenset?

1 Answers  


What is dynamic data structure?

2 Answers  


Is int a data structure?

1 Answers  


What is array and string?

1 Answers  


Is arraylist a class?

1 Answers  


Categories