当前位置:网站首页>Special topic of binary tree -- acwing 3384 Binary tree traversal (known preorder traversal, while building a tree, while outputting middle order traversal)
Special topic of binary tree -- acwing 3384 Binary tree traversal (known preorder traversal, while building a tree, while outputting middle order traversal)
2022-07-02 10:59:00 【Morgannr】

#define _CRT_SECURE_NO_WARNINGS 1
#include <bits/stdc++.h>
using namespace std;
//#define int long long
//#define map unordered_map
using namespace std;
void dfs()
{
char ch; cin>>ch;
if(ch == '#') return ;
dfs();
cout << ch << ' ';
dfs();
}
int main()
{
dfs();
return 0;
}
边栏推荐
猜你喜欢

618 what is the secret of dominating the list again? Nike's latest financial report gives the answer

VSCode工具使用

【AppLinking实战案例】通过AppLinking分享应用内图片

2022爱分析· 国央企数字化厂商全景报告

JSP webshell免殺——JSP的基礎

SPSS做Shapiro-Wilk正态分析

"Matching" is true love, a new attitude for young people to make friends

UVM learning - build a simple UVM verification platform

如何使用IDE自动签名调试鸿蒙应用

Nodejs+express+mysql simple blog building
随机推荐
UVM - configuration mechanism
华为快应用中如何实现同时传递事件对象和自定义参数
static 函数中的静态变量
[AI application] Hikvision ivms-4200 software installation
全网显示 IP 归属地,是怎么实现的?
Ks009 implement pet management system based on SSH
二叉树专题--AcWing 1497. 树的遍历(利用后、中序遍历,构建二叉树)
洛谷 P3398 仓鼠找 sugar(树上倍增 lca 判断树中两条路径是否相交 结论)
二叉树专题--洛谷 P3884 [JLOI2009]二叉树问题(dfs求二叉树深度 bfs求二叉树宽度 dijkstra求最短路)
如何用list组件实现tabbar标题栏
PCL之滤波
12.进程同步与信号量
K-d tree and octree of PCL
axis设备的rtsp setup头中的url不能带参
P1055 [noip2008 popularization group] ISBN number
【ARK UI】HarmonyOS ETS的启动页的实现
MySQL lethal serial question 4 -- are you familiar with MySQL logs?
AttributeError: type object ‘Image‘ has no attribute ‘fromarray‘
Easyexcel, a concise, fast and memory saving excel processing tool
JS settimeout() and interview questions