int LeafCount(BiTree T)
{
if(T==NULL)
return 0;
if(T->lchild==NULL&&T->rchild==NULL)
return 1;
else
return LeafCount(T->lchild)+LeafCound(T->rchild);
}
转载于:https://www.cnblogs.com/-xss/p/6011929.html
int LeafCount(BiTree T)
{
if(T==NULL)
return 0;
if(T->lchild==NULL&&T->rchild==NULL)
return 1;
else
return LeafCount(T->lchild)+LeafCound(T->rchild);
}
转载于:https://www.cnblogs.com/-xss/p/6011929.html