Category Archives: Linked List

Write a C program to return the nth node from the end of a linked list

Solution 01 – Brute Force Approach: Let’s assume length of linked list be ‘L’ , nth node from end = L – n + 1 node from start. Step 1: Iterate over the linked list and determine its length. Step 2: Now using the above mentioned formula , we can determine the position of the Read More →