Palindrome code not working properly linked list

@shabadsingh where are you finding the reverse of linked list for comparrison. basically your comparrison logic is incorrect.

@himanshu_aswal i have kept a pointer x to move it to the last of the linked list and compare data of head and first element
Then i have delete x that is the last element and made a recursive call by passing head->next as argument

@shabadsingh hey your approach is wrong . What can you do is that first find reverse of linked list and then compare both the linked list by traversing on both of them side by side.

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.