码迷,mamicode.com
首页 >  
搜索关键字:binary    ( 11734个结果)
Add Binary
Given two binary strings, return their sum (also a binary string).For example,a ="11"b ="1"Return"100".Analyse: Using XOR(^) to compute the result of ...
分类:其他好文   时间:2015-04-18 11:25:04    阅读次数:105
94. Binary Tree Inorder Traversal
Given a binary tree, return theinordertraversal of its nodes' values.For example:Given binary tree{1,#,2,3}, 1 \ 2 / 3return[1,3,2].Note...
分类:其他好文   时间:2015-04-18 07:35:36    阅读次数:135
145. Binary Tree Postorder Traversal
Given a binary tree, return thepostordertraversal of its nodes' values.For example:Given binary tree{1,#,2,3}, 1 \ 2 / 3return[3,2,1].No...
分类:其他好文   时间:2015-04-18 07:33:53    阅读次数:118
144. Binary Tree Preorder Traversal
Given a binary tree, return thepreordertraversal of its nodes' values.For example:Given binary tree{1,#,2,3}, 1 \ 2 / 3return[1,2,3].先pu...
分类:其他好文   时间:2015-04-18 07:32:59    阅读次数:123
Construct Binary Tree from Inorder and Postorder Traversal
跟另一道题一样,不多说了public class Solution { public TreeNode buildTree(int[] inorder, int[] postorder) { // post就是pre的近似倒过来 if(inorder==null||...
分类:其他好文   时间:2015-04-18 06:26:50    阅读次数:175
Construct Binary Tree from Preorder and Inorder Traversal
refhttp://www.cnblogs.com/springfor/p/3884034.html以下解释摘抄自 爱做饭的小莹子“题目:Given preorder and inorder traversal of a tree, construct the binary tree.Note:Yo...
分类:其他好文   时间:2015-04-18 06:23:56    阅读次数:119
Linux 各目录的作用
/binbin是binary的缩写。这个目录沿袭了UNIX系统的结构,存放着使用者最经常使用的命令。例如cp、ls、cat,等等。/boot这里存放的是启动Linux时使用的一些核心文件。/devdev是device(设备)的缩写。这个目录下是所有Linux的外部设备,其功能类似DOS下的.sys和...
分类:系统相关   时间:2015-04-18 01:12:38    阅读次数:161
【leetcode】Binary Tree Preorder Traversal (middle)★
Given a binary tree, return thepreordertraversal of its nodes' values.For example:Given binary tree{1,#,2,3}, 1 \ 2 / 3return[1,2,3].二叉树...
分类:其他好文   时间:2015-04-17 22:06:08    阅读次数:106
leetcode_103题——Binary Tree Zigzag Level Order Traversal(广度优先搜索,队列queue,栈stack)
Binary Tree Zigzag Level Order TraversalTotal Accepted:31183Total Submissions:117840My SubmissionsQuestionSolutionGiven a binary tree, return thezigza...
分类:其他好文   时间:2015-04-17 21:53:46    阅读次数:123
leetcode_199题——Binary Tree Right Side View(广度优先搜索,队列queue)
#include#include#includeusing namespace std;// Definition for binary tree struct TreeNode { int val; TreeNode *left; TreeNode *right; TreeNode(int...
分类:其他好文   时间:2015-04-17 21:51:07    阅读次数:141
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!