码迷,mamicode.com
首页 >  
搜索关键字:binary    ( 11734个结果)
[LeetCode]Binary Tree Postorder Traversal
Q:Given a binary tree, return the postorder traversal of its nodes' values. Note:Recursive solution is trivial, could you do it iteratively? 题目的意思就是不用递归求二叉树的后序遍历。 后续遍历的递归方式很简单,首先遍历左子树,然后遍历右子树,最...
分类:其他好文   时间:2015-01-31 14:49:58    阅读次数:156
leetcode 129. Sum Root to Leaf Numbers
Given a binary tree containing digits from0-9only, each root-to-leaf path could represent a number.An example is the root-to-leaf path1->2->3which rep...
分类:其他好文   时间:2015-01-31 12:05:25    阅读次数:209
Flatten Binary Tree to Linked List
Given a binary tree, flatten it to a linked list in-place. For example, Given 1 / 2 5 / \ 3 4 6 The flattened tree should look like: 1 ...
分类:其他好文   时间:2015-01-30 22:58:55    阅读次数:299
Path Sum II
Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum. For example: Given the below binary tree and sum = 22, 5 / ...
分类:其他好文   时间:2015-01-30 22:56:04    阅读次数:128
116.Populating Next Right Pointers in Each Node
Given a binary tree    struct TreeLinkNode {      TreeLinkNode *left;      TreeLinkNode *right;      TreeLinkNode *next;     } Populate each next pointer to point to its next right node. If ...
分类:其他好文   时间:2015-01-30 22:54:04    阅读次数:139
96.Unique Binary Search Trees
Given n, how many structurally unique BST's (binarysearch trees) that store values 1...n? For example, Given n = 3, there are a total of 5 unique BST's.   1         3     3     2      1    \    ...
分类:其他好文   时间:2015-01-30 22:53:46    阅读次数:166
94.Binary Tree Inorder Traversal(非递归中序遍历)
Given a binary tree, return the inorder traversal of itsnodes' values. For example: Given binary tree {1,#,2,3},    1         2     /    3 return [1,3,2]. Note: Recursive solution istri...
分类:其他好文   时间:2015-01-30 22:53:42    阅读次数:203
144.Binary Tree Preorder Traversal(非递归前序遍历)
Given a binary tree, return the preorder traversal of itsnodes' values. For example: Given binary tree {1,#,2,3},    1         2     /    3 return [1,2,3]. Note: Recursive solution istr...
分类:其他好文   时间:2015-01-30 22:53:36    阅读次数:234
Construct Binary Tree from Inorder and Postorder Traversal
Given inorder and postorder traversal of a tree, construct the binary tree. Note: You may assume that duplicates do not exist in the tree. #include #include typedef struct TreeNode { int v...
分类:其他好文   时间:2015-01-30 22:50:28    阅读次数:266
数字通信(1)
模型的作用是考虑主要特征。统计学的稳态是统计特性不随时间发生变化。信源编码器进来的是二进制序列(数字信息/模拟信息数字化采样)(a sequence of binary digits)信源编码后的比特序列叫信息序列。(information sequence)信道编码器把每k个一组的比特序列映射到每...
分类:其他好文   时间:2015-01-30 19:26:50    阅读次数:177
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!