If I have a linked list of 3 elements 5 - 8 - 18 .
Now I say I want to remove 3rd element from the last , is there any way to modify this code to do this?
Kth From the End
Refer this approach. https://www.geeksforgeeks.org/delete-nth-node-from-the-end-of-the-given-linked-list/
This is the most optimal one.
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.