Question: ***PROCEDURAL CODE C++ *** C++ no c please!! please include any header files if needed to run *** Please add comments if you can Develop

***PROCEDURAL CODE C++

*** C++ no c please!! please include any header files if needed to run

*** Please add comments if you can

Develop a C++ program that will recursively alphabetize a set of strings in a user-specified file using the tree sort algorithm explained in the lectures while maintaining a balanced binary tree at all times.

Test your program with an input file containing:

Max Hank Jet Frisky Chata Richard Nan Sam Thomas Karen Gerri Ingrid Alan Dana

When done print out the contents of the tree in inorder in a tabular format similar to the following:

NODE

LEFT

RIGHT

HEIGHT

BALANCE

Clarise

null

null

1

0

Fred

Clarise

Henry

2

0

Henry

null

null

1

0

Jane

Fred

Nan

4

-1

Mark

null

null

1

0

Nan

Mark

Susan

3

-1

Ryan

null

null

1

0

Susan

Ryan

Tammy

2

0

Tammy

null

null

1

0

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!