![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
algorithm
文章平均质量分 61
supersource732
这个作者很懒,什么都没留下…
展开
-
刷题笔记17 二叉树Part IV
法1: 常规思路 数值裂解 求平方和 放入set 平方和在set中已经存在->no_happy 反之 happy。法1: 创建2个vector 并比较。原创 2023-05-28 10:35:20 · 27 阅读 · 0 评论 -
数组+双指针0406
/Java函数 int index = Arrays.binarySearch(sums, target);如果找到就会返回值的下标,如果没找到就会返回一个负数,这个负数取反之后就是查找的值应该在数组中的位置 [1] 搜索值不是数组元素,且在数组范围内,从1开始计数,得“ - 插入点索引值”;//构造函数 int search(vector<int>& nums, int target)while(sum >= target){//此处应为循环 实现重复出入队列。//双指针 快慢指针。原创 2023-04-07 11:42:01 · 450 阅读 · 1 评论 -
二分查找及数组相关
erase()是o(n)方法。704查找数组内特定值。原创 2023-04-06 22:55:25 · 63 阅读 · 1 评论