NEED A PERFECT PAPER? PLACE YOUR FIRST ORDER AND SAVE 15% USING COUPON:

SOLVED

11)A reference variable whose sole purpose is to locate the first node in a linked list is called ______. a)top b)front c)head d)first 12)Which of the following will be true when the reference variable curr references the last node in a linear linked list? a)curr == null b)head == null c)curr.getNext() == null d)head.getNext() == null 13)If a linked list is empty, the statement head.getNext() will throw a(n) ______. a)IllegalAccessException b)ArithmeticException c)IndexOutOfBoundsException d)NullPointerException 14)To delete a node N from a linear linked list, you will need to ______. a)set the reference next in the node that precedes N to reference the node that follows N b)set the reference next in the node that precedes N to reference N c)set the reference next in the node that follows N to reference the node that precedes N d)set the reference next in N to reference the node that follows N 15)Which of the following statements deletes the node that curr references? a)prev.setNext(curr); b)curr.setNext(prev); c)curr.setNext(curr.getNext()); d)prev.setNext(curr.getNext()); 16)Which of the following statements deletes the first node of a linear linked list that has 10 nodes? a)head.setNext(curr.getNext()); b)prev.setNext(curr.getNext()); c)head = head.getNext(); d)head = null; 17)An array-based implementation of an ADT list ______. a)requires less memory to store an item than a reference-based implementation b)is not a good choice for a small list c)has a variable size d)has items which explicitly reference the next items 18)In a reference-based implementation of an ADT list ______. a)increasing the size of the list can waste storage and time b)less memory is required to store an item than in an array-based implementation c)an item explicitly references the next item d)the location of the item after a particular item is implied 19)Which of the following statements is used to insert a new node, referenced by newNode, at the end of a linear linked list? a)newNode.setNext(curr); prev.setNext(newNode); b)newNode.setNext(head); head = newNode; c)prev.setNext(newNode); d)prev.setNext(curr); newNode.setNext(curr); 20)In a linear linked list, ______. a)the next reference of each node has the value null b)the last node references the first node c)the precede reference of the dummy head node references the last node d)the next reference of the last node has the value null

Solution:

15% off for this assignment.

Our Prices Start at $11.99. As Our First Client, Use Coupon Code GET15 to claim 15% Discount This Month!!

Why US?

100% Confidentiality

Information about customers is confidential and never disclosed to third parties.

Timely Delivery

No missed deadlines – 97% of assignments are completed in time.

Original Writing

We complete all papers from scratch. You can get a plagiarism report.

Money Back

If you are convinced that our writer has not followed your requirements, feel free to ask for a refund.