摘要: /*题目描述:输入:第一行为整数n(n >= 2),表示二叉树节点总数后面带n-1行,每行为整数a和整数b的输入格式,a表示父亲节点,b表示a的一个子节点输出:二叉树的深度示例输入:50 10 21 31 4输出:3*/#include #include using ... 阅读全文
posted @ 2016-09-24 00:35 Victor_Lv 阅读(320) 评论(0) 推荐(0) 编辑
摘要: /*题目描述:输入一行字符(可包含空格)将其反向输出示例:输入:hello world输出:dlrow olleh*/#include #include // support for stack template classusing namespace std;/... 阅读全文
posted @ 2016-09-24 00:06 Victor_Lv 阅读(589) 评论(0) 推荐(0) 编辑