码迷,mamicode.com
首页 >  
搜索关键字:binary    ( 11734个结果)
GrayCode for state machine
How & Why use Gray Code A gray counter is a binary counter where only one bit changes at a time. Gray code is mostly used to send values across clock
分类:系统相关   时间:2016-02-05 18:41:23    阅读次数:187
【树】Convert Sorted Array to Binary Search Tree
题目: Given an array where elements are sorted in ascending order, convert it to a height balanced BST. 思路: 找到数组的中间数据作为根节点,小于中间数据的数组来构造作为左子树,大于中间数据的数组来构
分类:其他好文   时间:2016-02-05 18:41:10    阅读次数:141
【树】Construct Binary Tree from Preorder and Inorder Traversal
题目: Given preorder and inorder traversal of a tree, construct the binary tree. 思路: 线序序列的第一个元素就是树根,然后在中序序列中找到这个元素(由于题目保证没有相同的元素,因此可以唯一找到),中序序列中这个元素的左边就
分类:其他好文   时间:2016-02-05 11:44:41    阅读次数:110
Java [Leetcode 111]Minimum Depth of Binary Tree
题目描述: Given a binary tree, find its minimum depth. The minimum depth is the number of nodes along the shortest path from the root node down to the nea
分类:编程语言   时间:2016-02-04 13:23:50    阅读次数:235
Groupon面经:Find paths in a binary tree summing to a target value
You are given a binary tree (not necessarily BST) in which each node contains a value. Design an algorithm to print all paths which sum up to that val
分类:其他好文   时间:2016-02-04 12:29:30    阅读次数:120
*Gray Code
The gray code is a binary numeral system where two successive values differ in only one bit. Given a non-negative integer n representing the total num
分类:其他好文   时间:2016-02-04 06:45:56    阅读次数:227
HDU 3711 Binary Number
Binary Number Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 1879 Accepted Submission(s): 1133 P
分类:其他好文   时间:2016-02-03 20:04:32    阅读次数:256
Leetcode题解(30)
98. Validate Binary Search Tree 题目 分析:BST按照中序遍历之后所得到的序列是一个递增序列,因此可以按照这个思路,先中序遍历,保存好遍历的结果,然后在遍历一遍这个序列。判断其是否递增 代码如下: 1 /** 2 * Definition for a binary t
分类:其他好文   时间:2016-02-03 14:32:36    阅读次数:187
rpm
rpm 概述 rpm 执行安装包:二进制包(Binary)以及源代码包(Source)两种。二进制包可以直接安装在计算机中,而源代码包将会由RPM自动编译、安装。源代码包经常以src.rpm作为后缀名。 常用命令组合: rpm {-q|--query} [select-options] [query
分类:其他好文   时间:2016-02-03 11:39:37    阅读次数:158
二叉树的三种遍历(非递归)
先定义二叉树: /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode *left; * TreeNode *right; * TreeNode(int x) : val(x), left(
分类:其他好文   时间:2016-02-02 23:15:56    阅读次数:196
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!