java
朔北冥
每日进步一小点---每日一水。
展开
-
java io操作
java io 总结---主要使用对象及方法。原创 2016-11-03 22:22:35 · 353 阅读 · 0 评论 -
LeetCode 6. ZigZag Conversion
leetcode 题目The string "PAYPALISHIRING" is written in a zigzag pattern on a given number of rows like this: (you may want to display this pattern in a fixed font for better legibility)P A H原创 2016-11-05 21:31:51 · 306 阅读 · 0 评论 -
LeetCode 41. First Missing Positive
41. First Missing PositiveGiven an unsorted integer array, find the first missing positiveinteger.For example,Given [1,2,0] return 3,and [3,4,-1,1] return 2.Your algorithm should run in O(n)原创 2017-03-29 20:56:30 · 371 阅读 · 0 评论 -
LeetCode 42. Trapping Rain Water
Given n non-negativeintegers representing an elevation map where the width of each bar is 1,compute how much water it is able to trap after raining.For example, Given [0,1,0,2,1,0,1,3,2,1,2,1]原创 2017-03-30 10:03:50 · 244 阅读 · 0 评论 -
LeetCode 45. Jump Game II
45. Jump Game IIGiven an array of non-negative integers, you are initiallypositioned at the first index of the array.Each element in the array represents your maximum jump length atthat position.原创 2017-03-30 21:26:21 · 356 阅读 · 0 评论 -
LeetCode 46. Permutations
LeetCode 46. PermutationsGiven a collection of distinct numbers,return all possible permutations. For example,[1,2,3] have the following permutations:[ [1,2,3], [1,3,2], [2,1,3], [2,原创 2017-11-21 11:38:07 · 258 阅读 · 0 评论