Wednesday, August 15, 2007

Write a C program to determine the number of elements (or size) in a tree.

int tree_size(struct node* node)
{
if (node==NULL)
{
return(0);
}
else
{
return(tree_size(node->left) + tree_size(node->right) + 1);
}
}

2 comments:

Anonymous said...

How to Create own CV in XHTML. Whenever a mouse cursor is taken over the marks fields of your BSC/BCA (or last degree course), then an Ajax request (hidden iframe) is to be made and response should contain the individual marks/precentage of each year of last degree course. This response should be displayed as tooltip/popup (like yahoo news) portion.

sandeep kumar said...

Thanks for the info. It is very helpful.

Regards
Educational site

Get jobs info at Educational site