/* compares tree and its mirror image */
int compare(bt *list, bt * list1)
{
int d;
if (list == NULL && list1 == NULL)
{
return 1;
}
else if (list != NULL && list1 != NULL)
{
return(list->value == list1->value &&
compare(list->l, list1->l) &&
compare(list->r, list1->r));
}
else
{
return 0;
}
}