Write a method called displayList that displays the data items in the Node class created in number 6 above.
What will be an ideal response?
```
public static void DisplayList(Node h)
{
Node current = h;
while(current != null)
{
System.out.println("The node contains " + current.getCityName() + " with
a pollution index of " + current.getPollutionCount());
current = current.getLink();
}
}
```
You might also like to view...
What type of programming techniques does C++ provide that the C language does not?
What will be an ideal response?
Which class is not a type-wrapper class?
a. Character b. Int c. Double d. Byte
Password crackers enable investigators to circumvent many ________ measures employed by the suspect
Fill in the blank(s) with the appropriate word(s).
What testing tool can be used to help ensure that a resource meets its requirements?
A. unittest B. pytest C. pyunit D. unitcheck