Algorithms and Me Its not mine alone... If you have any interesting topic or question with or without solution, please mail me @ jitsceait@gmail.com Problem statement Given a singly linked list, find if it is a palindrome or not. For example, 9->8->7->7->8->9->NULL is palindrome linked list 9->8->7-6->8->9->NULL is not a palindrome. Analysis By definition of palindrome, a string is palindrome if it reads forward and backwards same. To check if string is palindrome, standard way is to keep to pointers,
Read full article from Algorithms and Me
No comments:
Post a Comment