Question: Write a Java program that inserts English to Spanish translations into a binary tree to enable fast translation of text ( EnglishSpanish . csv The

Write a Java program that inserts English to Spanish translations into a binary tree to enable fast translation of text (EnglishSpanish.csv
The program should take English text as input and output the Spanish version by looking up one word after the other in the binary tree.
The goal is to minimize the height of your tree, as the fewer steps needed to find a word, the faster the translation will work. Adjust the insertion process to keep the overall height of the tree as low as possible. What is its height?
Optional - for 10/10:
Not all words are looked up as often. For example, "aardvark" will be looked up less often than "and". Modify the tree structure so that it keeps the "average steps per word" as low as possible (see EnglishFrequencies.csv). Translate a chunk of English text and evaluate the average steps per word. Can you get it lower? Can you think of something smart?
Write a Java program that inserts English to

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 Accounting Questions!