Question 3
Suppose each node of the linked list is an object of class Node. Variable head points to the first node of the linked list, and the list initially contains the following elements: 8 → 3 → 6 → 1 → 9 → 4 → 7 Consider the following function:
What will be the output of the given function if it is called on the head node of the given linked list?