码迷,mamicode.com
首页 >  
搜索关键字:binary trees    ( 12390个结果)
Max Consecutive Ones
Given a binary array, find the maximum number of consecutive 1s in this array. Example 1: Input: [1,1,0,1,1,1] Output: 3 Explanation: The first two di ...
分类:其他好文   时间:2017-09-03 10:10:36    阅读次数:213
Maximum Depth of Binary Tree
Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest l ...
分类:其他好文   时间:2017-09-03 10:08:39    阅读次数:133
LeetCode 572: Subtree of Another Tree
/** * Definition for a binary tree node. * public class TreeNode { * int val; * TreeNode left; * TreeNode right; * TreeNode(int x) { val = x; } * } */... ...
分类:其他好文   时间:2017-09-03 10:04:08    阅读次数:95
LeetCode 543: Diameter of Binary Tree
/** * Definition for a binary tree node. * public class TreeNode { * int val; * TreeNode left; * TreeNode right; * TreeNode(int x) { val = x; } * } */... ...
分类:其他好文   时间:2017-09-03 09:55:45    阅读次数:130
Merge Two Binary Trees(easy)
这个题被标记为easy,还是挺简单的,但因为我才入门,其实也碰到了一些问题 题目要求: Given two binary trees and imagine that when you put one of them to cover the other, some nodes of the two ...
分类:其他好文   时间:2017-09-03 01:08:36    阅读次数:125
.NET Framework 3.5中的LINQ简介
1. LINQ 概览 1.1. 数据访问现状 1.2. LINQ 数据访问方式 1.3. LINQ 项目 2. 访问数组 2.1. 查询数组 2.2. 绑定到页面 3. 访问集合 3.1. 自定义 City 类 3.2. 查询City 集合 3.3. 绑定到页面 3.4. 绑定页面结果 4. 查询投 ...
分类:Web程序   时间:2017-09-03 00:24:49    阅读次数:238
二进制运算基础
# 一、二进制位运算 1. 按位与(&) 位运算实质是将参与运算的数字转换为二进制,而后逐位对应进行运算。 按位与运算为:两位全为1,结果为1,即1&1=1,1&0=0,0&1=0,0&0=0。 例如51 & 5 -> 00110011 & 00000101 = 00000001 -> 51 & 5 ...
分类:其他好文   时间:2017-09-02 23:19:27    阅读次数:198
冲刺Noip2017模拟赛7 解题报告——五十岚芒果酱
1、二叉树(binary) 1.二叉树 (binary.cpp/c/pas) 【问题描述】 二叉排序树或者是一棵空树,或者是具有下列性质的二叉树: (1)若左子树不空,则左子树上所有结点的值均小于它的根结点的值; (2)若右子树不空,则右子树上所有结点的值均大于它的根结点的值; (3)左、右子树也分 ...
分类:其他好文   时间:2017-09-02 15:28:09    阅读次数:157
Spakr- ERROR Shell: Failed to locate the winutils binary in the hadoop binary path java.io.IOException: Could not locate executable null\bin\winutils.exe in the Hadoop binaries.
运行 报错 检查发现hadoop下bin目录下已经存在winutils.exe,检查hadoop的path路径,发现没有严格按照格式创建hadoop的path,真确的格式是HADOOP_HOME=...... ...
分类:编程语言   时间:2017-09-02 14:26:11    阅读次数:210
leetcode--114. Flatten Binary Tree to Linked List
1、问题描述 Given a binary tree, flatten it to a linked list in-place. For example,Given The flattened tree should look like: Hints: If you notice carefull ...
分类:其他好文   时间:2017-09-02 09:37:26    阅读次数:125
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!