Here is a C program using recursion
int identical(struct node* a, struct node* b)
{
if (a==NULL && b==NULL){return(true);}
else if (a!=NULL && b!=NULL)
{
return(a->data == b->data &&
identical(a->left, b->left) &&
identical(a->right, b->right));
}
else return(false);
}
Wednesday, August 15, 2007
Subscribe to:
Post Comments (Atom)
2 comments:
Thanks for the info.
Regards
Educational site
I feel that is among the most significant info for me.
And i'm happy studying your article. However wanna observation on some general issues, The website style is perfect, the articles is in point of fact great : D. Good job, cheers
Stop by my page - Bmi Calculator Women
Post a Comment