1.双指针 双指针解决数组,字符串,二分搜索,链表翻转、判断是否有环、寻找链表向后数第i个元素、链表中间的元素。 1.1有序数组两数之和 left = 0,right = arr.len 1 若arr[left]+arr[right] sum,right ;否则left++; 1.2最小子串(双指针 ...
分类:
其他好文 时间:
2020-04-22 22:52:53
阅读次数:
81
1.节点数据结构 public class Node { public int value; public Node left; public Node right; public Node(int data){ this.value = value; } } 2.递归 public class R ...
分类:
编程语言 时间:
2020-04-22 13:39:29
阅读次数:
66
总结:1、查询时用 not in 效率极其低下,因此结合left join改为in查询,效率很快 原语句: select * from my_test_table where id not in (select b.id as id from ( SELECT MAX(a.`ModifyAt`)Mo ...
分类:
数据库 时间:
2020-04-22 13:26:47
阅读次数:
77
先完成‘左右两列竖直分别滑动,相互之间不存在任何关联’的页面样式: <t emplate> <div> <div class="flex-between"> <div class="left"> <span v-for="n in 16" :key="n">{{n}}</span> </div> < ...
分类:
其他好文 时间:
2020-04-22 12:55:38
阅读次数:
216
Min25筛 文章很多的向下取整省略了。。。 前言 为什么网上通行的写法和论文里不一样啊 问题引入 设质数集合为$p_i$,$n$包含的质因数集为$p(n)$,定义积性函数 $$F(n)=\left \{ \begin{aligned} 1 && n=1 \\ G(p_i) && n=p_i \\ ...
分类:
其他好文 时间:
2020-04-22 12:54:11
阅读次数:
52
左连接 ,右连接,内连接和全外连接的4者区别 答:left join (左连接):返回包括左表中的所有记录和右表中连接字段相等的记录。 right join (右连接):返回包括右表中的所有记录和左表中连接字段相等的记录。 inner join (等值连接或者叫内连接):只返回两个表中连接字段相等的 ...
分类:
其他好文 时间:
2020-04-22 10:23:58
阅读次数:
80
题目描述 Given an array nums, there is a sliding window of size k which is moving from the very left of the array to the very right. You can only see the ...
在Vue项目开发中我们经常要向页面中添加背景图片,可是当我们在样式中添加了背景图片后,编译打包后,配置到服务器上时,由于路径解析的问题,图片并不能够正确的显示出来,如下CSS样式: background:url("../../assets/left-bg.jpg"); 这个时候我们就要考虑使用其他的 ...
分类:
其他好文 时间:
2020-04-21 22:31:55
阅读次数:
151
update SmokeVehicle set IsLocal=1 where left(vlpn, 2)='冀F' update SmokeVehicle set IsLocal=2 where left(vlpn, 2)!='冀F' and left(vlpn, 1)='冀'update Smo ...
分类:
数据库 时间:
2020-04-21 18:22:50
阅读次数:
71
相对定位 定位有三种: 1.相对定位 2.绝对定位 3.固定定位 相对定位:相对于自己原来的位置定位 现象和使用: 1.如果对当前元素仅仅设置了相对定位,那么与标准流的盒子什么区别。 2.设置相对定位之后,我们才可以使用四个方向的属性: top、bottom、left、right 特性: 1.不脱标 ...
分类:
Web程序 时间:
2020-04-21 15:25:37
阅读次数:
82