Linked List -K append

https://ide.geeksforgeeks.org/2r1jJJTOJb-------what’s the error in my code i have used approach shown in hint for this question still in am getting tle, help me to correct it

you have not handled the condition when k>n. in these cases k = k%n. so in your function call, you should pass n%N.
Thanks

https://ide.geeksforgeeks.org/47hV2eYcNx---i have tried your solution but that didn’t worked , help me out

your solution wont work for one corner case, when k=0. think about it why?
your curr pointer will become null. so just write if(k==0) return;

Thanks

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.