Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

Reverse a Linked List

	    /* Before changing next pointer of current node,
        store the next node */
        next = curr -> next
        /*  Change next pointer of current node */
        /* Actual reversing */
        curr -> next = prev
        /*  Move prev and curr one step ahead */
        prev = curr
        curr = next
Source by www.faceprep.in #
 
PREVIOUS NEXT
Tagged: #Reverse #Linked #List
ADD COMMENT
Topic
Name
2+5 =