二叉树创建运行不成功,帮我看一下那里错了
//二叉树#include "stdio.h"
#include "malloc.h"
typedef char DataType;
typedef struct node
{
DataType data;
struct node *LChild,*RChild;
}BiTnode,*Bitree;
void createTree(Bitree *L)
{
char ch;
ch=getchar();
if(ch=='.')
*L=NULL;
else
{
*L=(Bitree)malloc(sizeof(BiTnode));
(*L)->data=ch;
createTree(&((*L)->LChild));
createTree(&((*L)->RChild));
}
}
void main()
{
Bitree *L;
createTree(L);
}