Fluffykitten5075 Fluffykitten5075
  • 02-09-2019
  • Computers and Technology
contestada

Which method of traversing a tree would result in a sorted list for a binary search tree?

Respuesta :

StaceeLichtenstein StaceeLichtenstein
  • 05-09-2019

Answer:

The inorder traversal make a binary search tree sorted.

Explanation:

The algorithm of inorder traversal is

1.  Traverse the left subtree.

2.  print the data .

3. Traverse the right subtree

In this algorithm left subtree  is visited first then it print the data or visit the data and finally it visited Right subtree .

Answer Link

Otras preguntas

what planet starts with e?
what planet starts with e?
I am a polyhedron. I am a prism. my two bases are hexagon. my two other faces are rectangles.
Simple Machine Lever: A ________ that pivots on top of a fixed point called a _______.
THE EXPRESSION COT THETA/CSC THETA IS EQUAL TO?
The skeletal system does all of the following EXCEPT (A) support. (B) transport. (C) protect. (D) digest. (E) store.
Mrs.Savin receives a weekly base salary of $500,plus a commission of $1200 on each car that she sells. Write a function rule relating her total weekly pay p to
THE EXPRESSION COT THETA/CSC THETA IS EQUAL TO?
what planet starts with e?
which organism would more closely resemble it's parent,one produced by asexual reproduction,or one produced by sexual reproduction? why?