typedef struct BiTNode{
ElemType data;
struct BiTNode *lchild,*rchild;
}BiTNode,*BiTree;
void Exchange(BiTree T)
{
if(T->lchild!==NULL || T->rchild!=NULL)
{
BiTree s=T->lchild;
T->lchild=T->rchild;
T->rchild=s;
}
if(T->lchild!=NULL)
Exchange(T->lchild);
if(T->rchild!=NULL)
Exchange(T->rchild);
}
后来又发现更简便的