Create tree ( Using preorder and inorder)

in this question plz explain the display function wisely, algo to print the output??? plz asap,ty

Basically, if you carefully notice by dry run, you will analyze that it is preorder printing of tree, with constraints, or conditions, like for eg,
if(root->left!=NULL && root->right==NULL)
{
cout<left->data<<" => β€œ<data<<” <= β€œ<<β€œEND”<<endl;
}
if(root->left ==NULL && root->right==NULL)
{
cout<<β€œEND”<<” => β€œ<data<<” <= "<<β€œEND”<<endl;
}

you need to first analyze the tree and its order carefully, only then you will be able to get this printing.