码迷,mamicode.com
首页 >  
搜索关键字:sorted    ( 5925个结果
Convert Sorted List to Binary Search Tree
Given a singly linked list where elements are sorted in ascending order, convert it to a height balanced BST. Given a singly linked list where element ...
分类:其他好文   时间:2019-06-03 23:35:02    阅读次数:108
letecode [26] - Remove Duplicates from Sorted Array
Share Share Given a sorted array nums, remove the duplicates in-place such that each element appear only once and return the new length. Do not alloca ...
分类:其他好文   时间:2019-06-03 10:50:44    阅读次数:127
LeetCode 977. Squares of a Sorted Array
977. Squares of a Sorted Array(有序数组的平方) 题目: 给定一个按非递减顺序排序的整数数组 A,返回每个数字的平方组成的新数组,要求也按非递减顺序排序。 示例 1: 示例 2: 提示: 思路: 非递减顺序,再加上存在负数,可以通过在两端比较:先取head和tail表示 ...
分类:其他好文   时间:2019-06-03 10:45:38    阅读次数:90
求中位数
|--1.python实现 | 测试用例 思考如何使用快排算法实现 ...
分类:其他好文   时间:2019-06-02 21:48:27    阅读次数:123
LeetCode 23. 合并K个排序链表(Merge Two Sorted Lists)
23. 合并K个排序链表 23. Merge k Sorted Lists 题目描述 合并 k 个排序链表,返回合并后的排序链表。请分析和描述算法的复杂度。 LeetCode23. Merge k Sorted Lists困难 示例: 输入: [   1 4 5,  & ...
分类:编程语言   时间:2019-06-01 19:15:57    阅读次数:79
链表Linked List注意事项
Q: 在扫整个链表的时候,到底什么时候用 while(cur!=null) 什么时候用 while(cur.next!=null) 呢? 以[leetcode]83. Remove Duplicates from Sorted List有序链表去重(有重去重)和[leetcode]82. Remov ...
分类:其他好文   时间:2019-06-01 09:26:17    阅读次数:177
11-215. Kth Largest Element in an Array
题目描述: Find the kth largest element in an unsorted array. Note that it is the kth largest element in the sorted order, not the kth distinct element. Ex ...
分类:其他好文   时间:2019-05-31 01:07:55    阅读次数:119
jdk1.8 -- stream 的使用
一.stream介绍 stream 是jdk 一个加强的api操作,翻译过来就是流的意思,主要是对Collection 集合的一些操作,流一但生成就会有方向性,类似于自来水管的水流一样,不可以重复使用。 stream 中的操作有filter map limt sorted collect 二.生成s ...
分类:其他好文   时间:2019-05-30 10:38:43    阅读次数:108
redis
redis是一个key-value存储系统。和Memcached类似,它支持存储的value类型相对更多,包括string(字符串)、list(链表)、set(集合)、zset(sorted set --有序集合)和hash(哈希类型)。这些数据类型都支持push/pop、add/remove及取交 ...
分类:其他好文   时间:2019-05-30 01:21:51    阅读次数:123
[LeetCode] Minimum Spanning Tree
Given a list of Connections, which is the Connection class (the city name at both ends of the edge and a cost between them), find edges that can conne ...
分类:其他好文   时间:2019-05-29 15:02:31    阅读次数:127
5925条   上一页 1 ... 64 65 66 67 68 ... 593 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!