Find the kth node in the linked list

@akshat42bajpai just keep the head pointer with you always updated whenever you need to print the list use that head pointed

so basically i have to pass head by reference in the kth function??

Yes that can be done

can you help once more i am not able to print

@akshat42bajpai Sure wrap up this doubt ask another one with a eg test case what you actually wanna do

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.