I am having difficulty in how to use true and false given in this problem used for making tree
How to take the input
node *build(string s){
if(s=="true"){
int d;
cin>>d;
node *root = new node(d);
string l;
cin>>l;
if(l=="true"){
root->left=build(l);
}
string r;
cin>>r;
if(r=="true"){
root->right=build(r);
}
return root;
}
return NULL;
}