zl程序教程

您现在的位置是:首页 >  后端

当前栏目

算法-二叉树的镜像详解编程语言

2023-06-13 09:20:44 时间
 TreeNode *right;  TreeNode(int x) : val(x), left(NULL), right(NULL) {} class Solution{ public:  void Mirror(TreeNode *pRoot){  if(pRoot == NULL)  return;  swap(pRoot- left, pRoot- right);  Mirror(pRoot- left);  Mirror(pRoot- right);  } int main()  return 0; }

原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/15258.html

cgo