if(tree !nullprintf("% \ "tree->data)preordertraversal(tree->left)preordertraversal(tree->right)void inordertraversal(struct node *treeif(tree !nullinordertraversal(tree->left)printf("% \ "tree->data)inordertraversal(tree->right)void postordertraversal(struct node *treeif(tree !nullpostordertraversal(tree->left)postordertraversal(tree->right)printf("% \ "tree->data)struct node *findsmallestelement(struct node *treeif(tree =null|(tree->left =null)return treeelse return findsmallestelement(tree ->left)struct node *findlargestelement(struct node *treeif(tree =null|(tree->right =null)return treeelse return findlargestelement(tree->right)struct node *deleteelement(struct node *treeint valstruct node *cur*parent*suc*psuc*ptrif(tree->left==nullprintf("\ the tree is empty ")return(tree)parent treecur tree->leftwhile(cur!=null &val!cur->dataparent curcur (valdata)cur->left:cur->rightif(cur =nullprintf("\ the value to be deleted is not present in the tree")return(tree)if(cur->left =nullptr cur->rightelse if(cur->right =null