Digital Stronghold - Software Engineering Blog




November 23, 2005

Printing a list using recursion

Filed under: Progressive Studies

This is a function for displaying a list. Oh I just love recursion.

void print_list(LINK head)
{
        if (head == NULL)
                printf("NULL");
	
        else {
                printf("%c --> ", head -> d;
                print_list(head -> next);
        }
}

Comments »

The URI to TrackBack this entry is: http://eradicus.blogsome.com/2005/11/23/printing-a-list-using-recursion/trackback/

No comments yet.

RSS feed for comments on this post.

Leave a comment

Line and paragraph breaks automatic, e-mail address never displayed, HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>



Anti-spam measure: please retype the above text into the box provided.

Theme designed by Joset Anthony Zamora


Digital Stronghold

↑ Get Headline Animator