Print the list in reverse order

Newbie Member
17Sep2007,14:11   #1
sandesh's Avatar
Hi.............
we can reverse print the link list without changing the list
we use recursion for this purpose ...............
code is like..........

Code:
void printreverse(node *head)
{
        if(head)
        {
                printfreverse(head->next);
                printf("  -> %d",head->data);
        }
}
if anyone of you have any query on queue ,stack and link list then we can discussion on that topics............

Last edited by shabbir; 17Sep2007 at 17:49.. Reason: Code block