一、Find 概述 可以根据文件的名称、文件大小、文件的修改时间、文件的类型、文件的权限、文件的属主属组、文件的目录层级进行查找 Find的语法: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] [pat ...
分类:
其他好文 时间:
2020-07-28 17:17:41
阅读次数:
98
思路: 公共祖先需要分为三种情况: 1.pq包含在root的左右子树中,则root就是他们公共祖先 2.pq包含在root的右子树中,则公共祖先是右子树 3.pq包含在root的左子树中,则公共祖先在左子树 代码: /** * Definition for a binary tree node. * ...
分类:
其他好文 时间:
2020-07-28 17:01:57
阅读次数:
59
测试代码Github地址:https://github.com/zhouyanger/java_demo/tree/master/netty 四.Netty 4.1 概述 Netty 是由 JBOSS 提供的一个 Java 开源框架。Netty 提供异步的、基于事件驱动的网络 应用程序框架,用以快速 ...
分类:
Web程序 时间:
2020-07-28 13:59:55
阅读次数:
72
测试代码Github地址:https://github.com/zhouyanger/java_demo/tree/master/netty 五.自定义 RPC 5.1 概述 RPC(Remote Procedure Call),即远程过程调用,它是一种通过网络从远程计算机程序 上请求服务,而不需要 ...
分类:
其他好文 时间:
2020-07-28 13:58:23
阅读次数:
69
#!/usr/bin/python from lxml import etree if __name__ == "__main__": #实例化一个etree对象,且将被解析的源码加载到了该对象中 tree = etree.parse('test.html') r = tree.xpath('./h ...
分类:
其他好文 时间:
2020-07-28 10:13:54
阅读次数:
68
思路: 中序:左->根->右 1.需要一个建立一个栈,首先将左子树放入栈中 2.获取栈顶元素并进行节点判断是否有右子树 3. 代码: /** * Definition for a binary tree node. * struct TreeNode { * int val; * TreeNode ...
分类:
其他好文 时间:
2020-07-27 23:50:51
阅读次数:
62
题目链接 https://leetcode-cn.com/problems/binary-tree-maximum-path-sum/ 题解 递归解法 路径:一条从树中任意节点出发,达到任意节点的序列。该路径至少包含一个节点,且不一定经过根节点。 这道题和LeetCode687最长同值路径和Leet ...
分类:
其他好文 时间:
2020-07-27 23:35:37
阅读次数:
74
//It is made by jump~ #include <iostream> #include <cstdlib> #include <cstring> #include <cstdio> #include <cmath> #include <algorithm> #include <ctim ...
分类:
其他好文 时间:
2020-07-27 17:46:04
阅读次数:
68
Given the root of a binary tree and an integer distance. A pair of two different leaf nodes of a binary tree is said to be good if the length of the s ...
分类:
其他好文 时间:
2020-07-27 15:58:17
阅读次数:
93
解决办法 在项目内添加一个 .npmrc 文件: 代码 //sass sass_binary_site=https://npm.taobao.org/mirrors/node-sass/ phantomjs_cdnurl=https://npm.taobao.org/mirrors/phantomj ...
分类:
其他好文 时间:
2020-07-27 15:51:45
阅读次数:
89