![](https://img-blog.csdnimg.cn/20201014180756930.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
刷题
文章平均质量分 88
laeen
开心就笑,不开心过会儿在笑。
展开
-
CCFCSP 201612-3权限查询
CCFCSP 201612-3权限查询问题描述 授权 (authorization) 是各类业务系统不可缺少的组成部分,系统用户通过授权机制获得系统中各个模块的操作权限。 本题中的授权机制是这样设计的:每位用户具有若干角色,每种角色具有若干权限。例如,用户 david 具有 manager 角色,manager 角色有 crm:2 权限,则用户 david 具有 crm:2 权限,原创 2017-02-06 14:53:16 · 1644 阅读 · 0 评论 -
leetcode - 57. Insert Interval
57. Insert IntervalGiven a set of non-overlapping intervals,insert a new interval into the intervals (merge if necessary). You may assume that the intervals wereinitially sorted according to the原创 2017-03-08 19:48:15 · 242 阅读 · 0 评论 -
leetcode - 56. Merge Intervals
56. Merge IntervalsGiven a collection ofintervals, merge all overlapping intervals.For example,Given [1,3],[2,6],[8,10],[15,18],return [1,6],[8,10],[15,18]./** *Definition for an interval.原创 2017-03-07 19:12:12 · 196 阅读 · 0 评论 -
leetcode - 39. Combination Sum
39. Combination SumGiven a set ofcandidate numbers (C) (without duplicates) and atarget number (T), find all unique combinations in C wherethe candidate numbers sums to T.The same repeatednumber原创 2017-02-27 11:10:34 · 331 阅读 · 0 评论 -
leetcode - 41. First Missing Positive
41. First Missing Positive Given an unsorted integerarray, find the first missing positive integer.For example,Given [1,2,0] return 3,and [3,4,-1,1] return 2.Your algorithm should runin O(原创 2017-02-27 16:47:47 · 199 阅读 · 0 评论 -
leetcode - 62. Unique Paths
62. Unique Paths A robot is located at thetop-left corner of a m x n grid (marked 'Start' in the diagrambelow).The robot can only move either down or right at any point intime. The robot is tryi原创 2017-03-09 19:12:05 · 295 阅读 · 0 评论 -
leetcode - 1 two sum
大三了,加油。原创 2017-01-16 08:42:07 · 358 阅读 · 0 评论 -
leetcode - 64. Minimum Path Sum
64. Minimum Path SumGiven a m x n gridfilled with non-negative numbers, find a path from top left to bottom rightwhich minimizes the sum of all numbers along its path.Note: You can only move eithe原创 2017-03-25 09:57:30 · 257 阅读 · 0 评论 -
leetcode - 73. Set Matrix Zeroes
73. Set Matrix ZeroesGiven a m x n matrix,if an element is 0, set its entire row and column to 0. Do it in place.click to show follow up.Follow up:Did you useextra space?A straight forward s原创 2017-04-04 11:56:54 · 514 阅读 · 0 评论 -
leetcode - 47. Permutations II(全排列)
47. Permutations IIGiven a collection of numbers that mightcontain duplicates, return all possible unique permutations. For example,[1,1,2] have the following uniquepermutations:[ [1,1,2],原创 2017-06-29 16:21:55 · 796 阅读 · 0 评论 -
leetcode - 26 Remove Duplicates from Sorted Array
Remove Duplicates from Sorted ArrayGiven a sorted array,remove the duplicates in place such that each element appear only once and return the new length.Do not allocate extra space for another arr原创 2017-01-21 09:20:26 · 185 阅读 · 0 评论 -
leetcode - 55. Jump Game
55. Jump GameGiven an arrayof non-negative integers, you are initially positioned at the first index ofthe array. Each element inthe array represents your maximum jump length at that position.原创 2017-03-03 13:13:13 · 277 阅读 · 0 评论 -
leetcode 11 - Container With Most Water
Given n non-negative integers a1, a2, ..., an, where each represents a point at coordinate (i, ai). n vertical lines are drawn such that thetwo endpoints of line i isat (i, ai) and (i,0). Find two原创 2017-01-17 12:58:43 · 253 阅读 · 0 评论 -
leetcode -15 3sum
3SumGiven anarray S of n integers,are there elements a, b, c in S such that a + b + c = 0? Find all unique triplets in thearray which gives the sum of zero. 找到一个数组中3个数字。使得3个数字相加等于0。 方法1:O(原创 2017-01-18 14:43:12 · 346 阅读 · 0 评论 -
leetcode - 42. Trapping Rain Water
42. Trapping Rain WaterGiven n non-negative integers representing anelevation map where the width of each bar is 1, compute how much water it isable to trap after raining.For example, Given [0,1原创 2017-02-28 10:29:02 · 247 阅读 · 0 评论 -
leetcode -16 3Sum Closest
3Sum ClosestGiven an array S of n integers,find three integers in S suchthat the sum is closest to a given number, target. Return the sum of the threeintegers. You may assume that each input would h原创 2017-01-20 10:28:56 · 219 阅读 · 0 评论 -
leetcode -18 4Sum
4Sum Given an array S of n integers,are there elements a, b, c, and d in S such that a + b + c + d =target? Find all unique quadruplets in the array which gives the sum of target. 给定一个数组S里包含原创 2017-01-20 18:16:04 · 157 阅读 · 0 评论 -
leetcode - 27 Remove Element
27. Remove ElementGivenan array and a value, remove all instances of that value in place and returnthe new length.Do not allocate extra space for another array, you must do thisin place with const原创 2017-01-31 09:36:01 · 248 阅读 · 0 评论 -
leetcode - 31 Next Permutation
31. Next PermutationImplement next permutation,which rearranges numbers into the lexicographically next greater permutation ofnumbers.If such arrangement is not possible, it must rearrange it as t原创 2017-01-31 10:31:33 · 221 阅读 · 0 评论 -
leetcode - 33. Search in Rotated Sorted Array
33. Search in Rotated Sorted ArraySuppose an array sorted inascending order is rotated at some pivot unknown to you beforehand.(i.e., 0 1 2 4 5 6 7 might become 4 5 6 7 0 1 2).You are given a原创 2017-01-31 10:59:04 · 161 阅读 · 0 评论 -
leetcode - 34. Search for a Range
34. Search for a RangeGiven an array of integerssorted in ascending order, find the starting and ending position of a giventarget value.Your algorithm's runtime complexity must be in the order of原创 2017-01-31 11:52:39 · 191 阅读 · 0 评论 -
leetcode - 35.Search Insert Position
35. Search Insert PositionGiven a sorted array and atarget value, return the index if the target is found. If not, return the indexwhere it would be if it were inserted in order.You may assume nod原创 2017-02-01 21:11:19 · 192 阅读 · 0 评论 -
leetcode - 239. Sliding Window Maximum
239. Sliding Window MaximumGiven an array nums, there is a sliding window of size k which is moving from the very left of the array to the very right. You can only see the k numbers in the window.原创 2017-10-08 11:17:38 · 260 阅读 · 0 评论