#include <stdio.h>
#include <stdlib.h>
#define new(x) x=(node)malloc(sizeof(node))
typedef struct Lnode{
float data;
struct Lnode *left,*right,*parent;
} Lnode,*node,*nodetype;
main(){
nodetype root;
new(root);
printf("Input the root (float):\n");
scanf("%f",&(root->data));
printf("here");
printf("%f",root->data);
}
感谢楼下的解答!
-------------------------------------------------------------------------------------------
略