递归建树
TreeNode* Build(int & p,string str){
char c=str[p++];
if(c=='#'){
return NULL;
}
TreeNode* root=new TreeNode(c);
root->leftchild=Build(p,str);
root->rightchild=Build(p,str);
return root;
}
相关推荐
吴鹏阳:这个老师如果爱举报,你这门课确实可能挂科,这没办法。但是辅导员所谓的延毕,,怎么说呢,毕业生的就业率可是辅导员的一大考核,他咋可能为了一个逃课实习去损害自己的利益呢?