Question: If Node head points at the first node of a singly-linked list of 3 nodes, the statement cout next->next->next->data: (A) will compile and print nothing.

If Node head points at the first node of a singly-linked list of 3 nodes, the statement cout next->next->next->data: (A) will compile and print nothing. (B) will compile and print the item data (C) will compile then cause a run-time error (D) will not compile as it violates encapsulation. (E) will not compile because of a syntax error
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
