上一页 1 ··· 53 54 55 56 57 58 59 60 61 ··· 77 下一页
摘要: [抄题]: Suppose you have a long flowerbed in which some of the plots are planted and some are not. However, flowers cannot be planted in adjacent plots 阅读全文
posted @ 2018-04-22 15:50 苗妙苗 阅读(142) 评论(0) 推荐(0)
摘要: [抄题]: Given an integer array, you need to find one continuous subarray that if you only sort this subarray in ascending order, then the whole array wi 阅读全文
posted @ 2018-04-22 09:22 苗妙苗 阅读(110) 评论(0) 推荐(0)
摘要: [抄题]: In a given integer array nums, there is always exactly one largest element. Find whether the largest element in the array is at least twice as m 阅读全文
posted @ 2018-04-22 08:49 苗妙苗 阅读(113) 评论(0) 推荐(0)
摘要: [抄题]: Given an array consisting of n integers, find the contiguous subarray of given length k that has the maximum average value. And you need to outp 阅读全文
posted @ 2018-04-21 22:33 苗妙苗 阅读(324) 评论(0) 推荐(0)
摘要: [抄题]: Given a non-empty array of integers, return the third maximum number in this array. If it does not exist, return the maximum number. The time co 阅读全文
posted @ 2018-04-21 21:29 苗妙苗 阅读(621) 评论(0) 推荐(0)
摘要: [抄题]: Given an unsorted array of integers, find the length of longest continuous increasing subsequence (subarray). Example 1: Example 2: [暴力解法]: 时间分析 阅读全文
posted @ 2018-04-21 16:22 苗妙苗 阅读(126) 评论(0) 推荐(0)
摘要: [抄题]: Given an array with n integers, your task is to check if it could become non-decreasing by modifying at most 1 element. We define an array is no 阅读全文
posted @ 2018-04-21 15:49 苗妙苗 阅读(130) 评论(0) 推荐(0)
摘要: [抄题]: Given a 2D integer matrix M representing the gray scale of an image, you need to design a smoother to make the gray scale of each cell becomes t 阅读全文
posted @ 2018-04-21 10:31 苗妙苗 阅读(170) 评论(0) 推荐(0)
摘要: [抄题]: Given a list of words and two words word1 and word2, return the shortest distance between these two words in the list. For example,Assume that w 阅读全文
posted @ 2018-04-21 09:19 苗妙苗 阅读(178) 评论(0) 推荐(0)
摘要: [抄题]: Given a binary array, find the maximum number of consecutive 1s in this array. Example 1: [暴力解法]: 用temp,result,结果发现写起来很麻烦 时间分析: 空间分析: [优化后]: 时间分 阅读全文
posted @ 2018-04-20 22:11 苗妙苗 阅读(166) 评论(0) 推荐(0)
上一页 1 ··· 53 54 55 56 57 58 59 60 61 ··· 77 下一页