Write a recursive algorithm to delete the leaves of a binary tree.
You must use the binary search tree code provided. Each algorithm must be implemented as both a private method and a public method of the class. Your code will be tested using the program provided.
Use the input file provided, "input4.txt," to test your program. You should also test other trees to make sure all configurations will pass the tests.
Your output should match the sample output in "sample4.txt."