@Rishi:I think Shiva's code is also fine.U can access the list easily by using down pointer in his code. Because he is assigning temp->down=temp2 and then he is making temp->fwd=NULL.
On 12/20/10, Saurabh Koar <saurabhkoar...@gmail.com> wrote: > temp=head; > temp1=temp->fwd; > while(temp->fwd!=NULL) > { > temp2=temp; > while(temp2->down!=NULL) > temp2=temp2->link; > temp2->down=temp1; > temp->fwd=NULL; > temp=temp1; > temp1=temp1->fwd; > } > > U can print the linked list using down pointer.Hope this will > work.Correct me if I m wrong. > -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to algoge...@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.