Give the values of the List attributes after each of the following operations.

```
List ex = new LinkedList();
ex.add("Pooh");
ex.add(1, "Tigger");
ex.add(1, "Piglet");
ex.add(0, "Owl");
List exView = ex.sublist(1,4);
exView.clear();

```

```
List ex = new LinkedList();
size = 0, head = tail = null

ex.add("Pooh");
size = 1, head = tail =

ex.add(1, "Tigger");
size = 2, head = “Pooh” tail = “Tigger”

ex.add(1, "Piglet");
size = 3, head = “Pooh” tail = “Tigger”

ex.add(0, "Owl");
size = 4, head = “Owl” tail = “Tigger”

List exView = ex.sublist(1,4);
size = 4, head = “Owl” tail = “Tigger”
the sublist encompases “Pooh”, “Piglet” and “Tigger”

exView.clear();
size = 1, head = tail = “Owl”

```

Computer Science & Information Technology

You might also like to view...

What is an amortization schedule and what is its purpose?

What will be an ideal response?

Computer Science & Information Technology

A(n) ____ variable type is used to store logical (true or false) values.

A. Boolean B. Binary C. Object D. String

Computer Science & Information Technology