#include <stdio.h>
#include<stdlib.h>

struct node
{struct node *left;
struct node* right;
int element;
};



void insert(struct node **node,int x)
{
    if(*node==NULL)
    {
    	*node = malloc(sizeof(*node));
    	(*node)->element=x;
    	(*node)->left=NULL;
    	(*node)->right=NULL;
  	}else{
  		if(x<(*node)->element)
        {
        	insert(&((*node)->left),x);
        	}
    else
        {insert(&((*node)->right),x);}
    }
}
void inorder(struct node *base)
{
    if(base!=NULL)
    {inorder(base->left);
    printf("%d ",base->element);
    inorder(base->right);
    }
}


int main(int argc, char *argv[])
{struct node *base;
base = malloc(sizeof(*base));
base->element=1;
base->left=NULL;
base->right=NULL;
insert(&base,25);
insert(&base,30);
inorder(base);



    return 0;
}