In the Function stated here, he took the C Pointer to not equal to NULL Right? Isnt C->next = NULL The SAME???
Why Can't C->next!= NULL Work?
@JaveedYara yes at first step c->next can be null as p=NULL. but when c moves forward you cant
do c->next as null as we have to reverse the link list so c->next should point to prev
see this animation (scroll down) https://www.geeksforgeeks.org/reverse-a-linked-list/ (curr is c)
dont forget to hit like and mark resolved if cleared
1 Like
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.
1 Like