码迷,mamicode.com
首页 >  
搜索关键字:smallest    ( 560个结果
ARC097C K-th Substring
传送门 题目 You are given a string s. Among the different substrings of s, print the K-th lexicographically smallest one. A substring of s is a string obta ...
分类:其他好文   时间:2018-05-21 19:49:35    阅读次数:167
LeetCode - Kth Smallest Element in a BST
那么这道题给的提示是让我们用BST的性质来解题,最重要的性质是就是左<根<右,那么如果用中序遍历所有的节点就会得到一个有序数组。所以解题的关键还是中序遍历啊。 ...
分类:其他好文   时间:2018-05-21 14:38:58    阅读次数:176
两个没有解决的和素数(1e8)有关的题
Smallest Number (medium): 求1-N的LCM,多组数据。 Divisors of factorial (hard) 求N的阶乘的因子个数。 ...
分类:其他好文   时间:2018-05-21 14:35:03    阅读次数:122
First Missing Positive
41. First Missing Positive Given an unsorted integer array, find the smallest missing positive integer. Example 1: Example 2: Example 3: Note: Your al ...
分类:其他好文   时间:2018-05-20 15:19:29    阅读次数:180
Lintcode401 Kth Smallest Number in Sorted Matrix solution 题解
Lintcode401 Kth Smallest Number in Sorted Matrix solution 题解 ...
分类:其他好文   时间:2018-05-11 20:15:24    阅读次数:110
LeetCode-Microsoft-Remove K Digits
Given a non-negative integer num represented as a string, remove k digits from the number so that the new number is the smallest possible. Note: The l ...
分类:其他好文   时间:2018-04-29 11:41:03    阅读次数:147
744. Find Smallest Letter Greater Than Target 查找比目标字母大的最小字母
[抄题]: Given a list of sorted characters letters containing only lowercase letters, and given a target letter target, find the smallest element in the ...
分类:其他好文   时间:2018-04-28 23:50:23    阅读次数:269
378 Kth Smallest Element in a Sorted Matrix 有序矩阵中第K小的元素
给定一个 n x n 矩阵,其中每行和每列元素均按升序排序,找到矩阵中第k小的元素。请注意,它是排序后的第k小元素,而不是第k个元素。示例:matrix = [ [ 1, 5, 9], [10, 11, 13], [12, 13, 15]],k = 8,返回 13。说明:你可以假设 k 的值永远是有 ...
分类:其他好文   时间:2018-04-15 19:49:21    阅读次数:208
373 Find K Pairs with Smallest Sums 查找和最小的K对数字
给定两个以升序排列的整形数组 nums1 和 nums2, 以及一个整数 k。定义一对值 (u,v),其中第一个元素来自 nums1,第二个元素来自 nums2。找到和最小的 k 对数字 (u1,v1), (u2,v2) ... (uk,vk)。示例 1:给出: nums1 = [1,7,11], ...
分类:其他好文   时间:2018-04-15 17:15:57    阅读次数:201
洛谷P2851 [USACO06DEC]最少的硬币The Fewest Coins(完全背包+多重背包)
题目描述 Farmer John has gone to town to buy some farm supplies. Being a very efficient man, he always pays for his goods in such a way that the smallest ...
分类:其他好文   时间:2018-04-10 21:56:10    阅读次数:292
560条   上一页 1 ... 14 15 16 17 18 ... 56 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!