DFS层次遍历,设置层数n,在node中按层数创建该层的数组,dfs时每层加入该层对应数组。 /** * Definition for a binary tree node. * public class TreeNode { * int val; * TreeNode left; * TreeNo ...
分类:
其他好文 时间:
2021-02-09 12:27:15
阅读次数:
0
1.查询所有的POST /expert_experts/_search 2.查询记录数量countGET /expert_experts/_count 3.按照条件查询POST expert10_experts/_search{ "query" : { "match" : {"_id":"08d7e ...
分类:
其他好文 时间:
2021-02-08 12:26:24
阅读次数:
0
82. 删除排序链表中的重复元素 II Difficulty: 中等 给定一个排序链表,删除所有含有重复数字的节点,只保留原始链表中 _没有重复出现 _的数字。 示例 1: 输入: 1->2->3->3->4->4->5 输出: 1->2->5 示例 2: 输入: 1->1->1->2->3 输出: ...
分类:
编程语言 时间:
2021-02-02 11:02:03
阅读次数:
0
81. 搜索旋转排序数组 II Difficulty: 中等 假设按照升序排序的数组在预先未知的某个点上进行了旋转。 ( 例如,数组 [0,0,1,2,2,5,6] 可能变为 [2,5,6,0,0,1,2] )。 编写一个函数来判断给定的目标值是否存在于数组中。若存在返回 true,否则返回 fal ...
分类:
编程语言 时间:
2021-02-01 12:51:53
阅读次数:
0
正则表达式 使用方法: ①:描述我们要找的字符串的规律 ②:调用函数,执行该正则表达式 PHP: //把字符串haha找出来 $str="haha,this is my blog" preg_match_all('/haha/',$str,$res); print_r($res); 在PHP里正则必 ...
分类:
其他好文 时间:
2021-01-29 12:19:14
阅读次数:
0
每行的元素从左到右升序排列;每列的元素从上到下升序排列。找target是否在矩阵中 方法一:感觉跟问题I没啥区别啊! func searchMatrix(g [][]int, tar int) bool { n, m := len(g), len(g[0]) i, j := 0, m-1 for ; ...
分类:
其他好文 时间:
2021-01-28 12:14:07
阅读次数:
0
function is_weixin(){ var ua = navigator.userAgent.toLowerCase(); if(ua.match(/MicroMessenger/i)=="micromessenger") { return true; } else { return fal ...
分类:
微信 时间:
2021-01-26 12:38:44
阅读次数:
0
报错信息如下: Syntax Error: ValidationError: Invalid options object. Stylus Loader has been initialized using an options object that does not match the API ...
分类:
其他好文 时间:
2021-01-26 12:19:01
阅读次数:
0
本章节对赛普拉斯4Mbit(256K x 16)nvSRAM 和 MRAM器件分别在 44 引脚 TSOP-II(薄小外型封装-II 类型)和48球型焊盘 FBGA(小间距球栅阵列)封装选择中各自的引脚和封装区别进行了详细说明。 替换 44 TSOP-II 封装选择 图1显示的是使用 44 引脚 T ...
分类:
其他好文 时间:
2021-01-22 11:51:57
阅读次数:
0
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_ ...
分类:
其他好文 时间:
2021-01-21 10:51:22
阅读次数:
0