码迷,mamicode.com
首页 >  
搜索关键字:should be repaired    ( 4956个结果
Text Justification
Given an array of words and a lengthL, format the text such that each line has exactlyLcharacters and is fully (left and right) justified.You should p...
分类:其他好文   时间:2014-10-26 18:19:51    阅读次数:204
leetcode - Text Justification
Given an array of words and a length L, format the text such that each line has exactly L characters and is fully (left and right) justified. You should pack your words in a greedy approach; that i...
分类:其他好文   时间:2014-10-26 17:05:25    阅读次数:175
Two Sum
Given an array of integers, find two numbers such that they add up to a specific target number. The function twoSum should return indices of the two numbers such that they add up to the target, whe...
分类:其他好文   时间:2014-10-26 17:04:21    阅读次数:193
leetcode - First Missing Positive
Given an unsorted integer array, find the first missing positive integer. For example, Given [1,2,0] return 3, and [3,4,-1,1] return 2. Your algorithm should run in O(n) time and uses constant...
分类:其他好文   时间:2014-10-26 14:25:50    阅读次数:177
leetcode - Wildcard Matching
Implement wildcard pattern matching with support for '?' and '*'. '?' Matches any single character. '*' Matches any sequence of characters (including the empty sequence). The matching should cover t...
分类:其他好文   时间:2014-10-26 13:08:38    阅读次数:172
how to close the old Session - if the same username starts a new Session?
Question:want to close the old Session - if the same username starts a new SessionAny ideas how i can do this? - one user should not be able to start ...
分类:其他好文   时间:2014-10-26 10:19:28    阅读次数:267
leetcode-distinct sequences
Solution: when see question about two strings , DP should be considered first.We can abstract this question to calculate appear times for string T wit...
分类:其他好文   时间:2014-10-26 00:12:57    阅读次数:211
面试题:实现LRUCache::Least Recently Used的缩写,意思是最近最少使用,它是一种Cache替换算法
Design and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations:getandset.get(key)- Get the valu...
分类:编程语言   时间:2014-10-25 22:57:35    阅读次数:480
Partition List
Given a linked list and a valuex, partition it such that all nodes less thanxcome before nodes greater than or equal tox.You should preserve the origi...
分类:其他好文   时间:2014-10-25 15:47:52    阅读次数:225
为什么需要在TypedArray后调用recycle
当我们没有在使用TypedArray后调用recycle,编译器会提示“This TypedArray should be recycled after use with #recycle()”。官方的解释是:回收TypedArray,以便后面重用。在调用这个函数后,你就不能再使用这个TypedAr...
分类:其他好文   时间:2014-10-25 14:23:47    阅读次数:202
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!