Question: PART OF WORDPATH CLASS while (!queue.isEmpty()) { Node node = queue.poll(); ui.sendMessage(Polled); System.out.println(DEQUEUE: + node.word); 10 Add code to WordPath so it displays a
PART OF WORDPATH CLASS
while (!queue.isEmpty()) {
Node node = queue.poll();
ui.sendMessage("Polled");
System.out.println("DEQUEUE: " + node.word);

10 Add code to WordPath so it displays a message about how many times it polls the queue (Poll is expensive because you have the check the entire dictionary for neighbors. Add a class Nodecomparator that implements Comparator
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
