mac 上build go 如果想要在centos上面执行 必须使用下面的方式 CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -o hello hello.go 不然会报错 :cannot execute binary file ...
分类:
其他好文 时间:
2021-04-19 14:58:20
阅读次数:
0
翻转一棵二叉树。 示例: 输入: 4 / \ 2 7 / \ / \1 3 6 9输出: 4 / \ 7 2 / \ / \9 6 3 1 来源:力扣(LeetCode)链接:https://leetcode-cn.com/problems/invert-binary-tree著作权归领扣网络所有。 ...
分类:
其他好文 时间:
2021-04-19 14:42:03
阅读次数:
0
SQL Server 数据类型Oracle 数据类型 bigint NUMBER(19,0) binary(1-2000) RAW(1-2000) binary(2001-8000) BLOB bit NUMBER(1) char(1-2000) CHAR(1-2000) char(2001-400 ...
分类:
数据库 时间:
2021-04-16 11:43:58
阅读次数:
0
从网上看到了对一张超市购物小票做文字分割,于是想用Python+OpenCV实现从小票上面分割出字符,原图如下: 最后分割的效果如下图所示: 本文使用水平投影和垂直投影的方式进行图像分割,根据投影的区域大小尺寸分割每行和每块的区域,首先我们对原始图像进行二值化处理 然后分别进行水平投影和垂直投影: ...
分类:
编程语言 时间:
2021-04-14 12:36:31
阅读次数:
0
给你一个二叉搜索树的根节点 root ,返回 树中任意两不同节点值之间的最小差值 。 https://leetcode-cn.com/problems/minimum-distance-between-bst-nodes/ /** * Definition for a binary tree nod ...
分类:
其他好文 时间:
2021-04-13 12:43:51
阅读次数:
0
1. 翻转二叉树:https://leetcode-cn.com/problems/invert-binary-tree/ 2. 二叉树展开为链表,关键在于找到递归部分:https://leetcode-cn.com/problems/flatten-binary-tree-to-linked-li ...
分类:
其他好文 时间:
2021-04-13 12:42:14
阅读次数:
0
利用上一题求深度的做法 /** * Definition for a binary tree node. * public class TreeNode { * int val; * TreeNode left; * TreeNode right; * TreeNode(int x) { val = ...
分类:
其他好文 时间:
2021-04-13 12:05:30
阅读次数:
0
题目来源 Full Binary Tree Description In computer science,a binary tree is a tree data structure in which each node has at most two children. Consider an ...
分类:
其他好文 时间:
2021-04-13 12:02:15
阅读次数:
0
阈值类型 阈值产生的算法,阈值类型 THRESH_BINARY表示大于thresh的取maxval,否则取0; THRESH_BINARY_INV表示大于thresh的取0,否则取maxvalue; THRESH_TRUNC表示大于thresh取threshold,否则不改变灰度值; THRESH_ ...
分类:
编程语言 时间:
2021-04-13 11:43:12
阅读次数:
0
平衡二叉树 题目:输入一棵二叉树,判断该二叉树是否是平衡二叉树。 在这里,我们只需要考虑其平衡性,不需要考虑其是不是排序二叉树 平衡二叉树(Balanced Binary Tree),具有以下性质:它是一棵空树或它的左右两个子树的高度差的绝对值不超过1,并且左右两个子树都是一棵平衡二叉树。 func ...
分类:
其他好文 时间:
2021-04-12 11:48:28
阅读次数:
0