find length of linked list 1 say m find length of linked list2 say n take mod(m-n) say k
traverse k nodes in bigger lis after that both listts one position at a time until the pointers are equal On Fri, Sep 30, 2011 at 9:34 AM, partik madan <partikma...@gmail.com> wrote: > @annarao : as the common data is at the end of the linked lists so the > length of common data can not be greater than the length of shorter linked > list . so i think prasanth is right !! > >> >> > > > -- > *Partik Madan* > Computer Engm-n g. > NIT Kurukshetra > > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to algogeeks@googlegroups.com. > To unsubscribe from this group, send email to > algogeeks+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.