子指针}TNode,*Tree;/*建立二叉树函数*/intCreateTree(Tree&T)//按先序序列创建二叉树{chardata;scanf("%c",&data);if(data=='#')//‘#’表示空树?{T=NULL;}else?{//按先序序列输入二叉树T=(Tree)malloc(sizeof(TNode));T->data=data;CreateTree(T->lchild);CreateTree(T->rchild);}return0;}voidVisit(TreeT){if(T->data!='#')?{printf("%c",T->data);}}/*先序遍历函数*/voidPreOrder(TreeT){if(T!=NULL)?{Visit(T);PreOrder(T->lchild);PreOrder(T->rchild);}}/*中序遍历函数*/voidInOrder(TreeT){if(T!=NULL)?{InOrder(T->lchild);Visit(T);InOrder(T->rchild);}}/*后序遍历函数*/voidPostOrder(TreeT){if(T!=NULL)?{PostOrder(T->lchild);PostOrder(T->rchild);Visit(T);}}/*主函数*/intmain(){TreeT;CreateTree(T);printf("先序遍历:\n");PreOrder(T);printf("\n");printf("中序遍历:\n");InOrder(T);printf("\n");printf("后序遍历:\n");PostOrder(T);printf("\n");return0;}序号项目得分总分1实验报告排版(3分)2算法思想分析(6分)3源代码(6分)4实验结果及分析(5分)