Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

using java Write a program called TimeSymbolTables that creates two symbol table

ID: 3876158 • Letter: U

Question

using java Write a program called TimeSymbolTables that creates two symbol tables, one created with the class SequentialSearchST in the package algs31 and one created with the class BST in the package algs32. Each symbol table will contain as a key a word read from a text file and as a value the number of times that word occurs in the text file. Have the program fill the first symbol table with these counts, keeping track of how long that takes using a Stopwatch object, found in the stdlib package. It then does the same thing with the second symbol table. Finally, it prints out how long it took to fill each symbol table.

Explanation / Answer

public class X {
private static int value;
public class Y {
public void showIt() {
System.out.println("Value: " + value);
System.out.println("Value: " + getValue());
System.out.println("Value: " + X.getValue());
}
}
public static int getValue() {
return value;
}
}