自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(36)
  • 资源 (2)
  • 收藏
  • 关注

原创 Trapping Rain Water

每日算法——leetcode系列问题 Trapping Rain WaterDifficulty: Hard Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water it is able to trap after r

2016-01-26 21:26:28 282

原创 First Missing Positive

每日算法——leetcode系列问题 First Missing PositiveDifficulty: Hard Given an unsorted integer array, find the first missing positive integer. For example, Given [1,2,0] return 3, and [3,4,-1,1] ret

2016-01-24 20:51:00 309

原创 Combination Sum II

每日算法——leetcode系列问题 Combination Sum IIDifficulty: Medium Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T. Ea

2016-01-23 13:34:52 248

原创 Combination Sum

每日算法——leetcode系列问题 Combination SumDifficulty: Medium Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T. The s

2016-01-19 22:20:31 244

原创 Count and Say

每日算法——leetcode系列问题 Count and SayDifficulty: Easy The count-and-say sequence is the sequence of integers beginning as follows: 1, 11, 21, 1211, 111221, ... 1 is read off as "one 1" or 11.

2016-01-18 23:25:57 276

原创 Sudoku Solver

每日算法——leetcode系列问题 Sudoku SolverDifficulty: Hard Write a program to solve a Sudoku puzzle by filling the empty cells. Empty cells are indicated by the character '.'. You may assume that th

2016-01-17 23:24:48 317

原创 Valid Sudoku

每日算法——leetcode系列问题 Valid SudokuDifficulty: Easy Determine if a Sudoku is valid, according to: Sudoku Puzzles - The Rules. The Sudoku board could be partially filled, where empty cells are fille

2016-01-14 22:27:36 232

原创 Search Insert Position

每日算法——leetcode系列问题 SeSearch Insert PositionDifficulty: Medium Given a sorted array and a target value, return the index if the target is found. If not, return the index where it would be if it were

2016-01-12 22:48:39 187

原创 Search for a Range

每日算法——leetcode系列问题 Search for a RangeDifficulty: Medium Given a sorted array of integers, find the starting and ending position of a given target valwe. Your algorithm’s runtime complexity must

2016-01-11 22:23:59 249

原创 Search in Rotated Sorted Array

每日算法——leetcode系列问题 Search in Rotated Sorted ArrayDifficulty: Hard Suppose a sorted array 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).

2016-01-11 07:56:51 217

原创 Longest Valid Parentheses

每日算法——leetcode系列问题 Longest Valid ParenthesesDifficulty: Hard Given a string containing just the characters '(' and ')', find the length of the longest valid (well-formed) parentheses substring.

2016-01-10 22:29:01 219

原创 Mac终端用Sublime打开指定文件或文件夹

在Mac下用终端创建文件等比较方便,但如果配合Sublime用,最好是可以直接在终端中输入命令就可以用Sublime打开指定文件或文件夹。检查用户目录下有没有bin目录,如里没有就创建一个(目的是创建环境变量)$ cd ~在bin目录中建立Sublime的别名 (注意到你的应用程序看是不是这个名)$ sudo ln -s "/Applications/Sublime Text.app/Con

2016-01-10 22:00:01 588

原创 Next Permutation

每日算法——leetcode系列问题 Next PermutationDifficulty: Medium Implement next permutation, which rearranges numbers into the lexicographically next greater permutation of numbers. If such arrangement is

2016-01-09 09:51:50 221

原创 Substring with Concatenation of All Words

每日算法——leetcode系列问题 Substring with Concatenation of All WordsDifficulty: Hard You are given a string, s, and a list of words, words, that are all of the same length. Find all starting indices of subs

2016-01-07 22:05:36 340

原创 Divide Two Integers

每日算法——leetcode系列问题 Divide Two IntegersDifficulty: Medium Divide two integers without using multiplication, division and mod operator. If it is overflow, return MAX_INT.class Solution {public:

2016-01-06 22:46:51 279

原创 Implement strStr()

每日算法——leetcode系列问题 Implement strStr()Difficulty: Easy Implement strStr(). Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.class Solutio

2016-01-05 22:36:37 222

原创 Remove Element

每日算法——leetcode系列问题 Remove ElementDifficulty: Easy Given an array and a value, remove all instances of that value in place and return the new length. The order of elements can be changed. It does

2016-01-04 21:30:56 230

原创 Reverse Nodes in k-Group

每日算法——leetcode系列问题 Reverse Nodes in k-GroupDifficulty: Hard Given a linked list, reverse the nodes of a linked list k at a time and return its modified list. If the number of nodes is not a mult

2015-12-31 08:10:13 247

原创 Generate Parentheses

每日算法——leetcode系列问题 Generate ParenthesesDifficulty: Medium Given n pairs of parentheses, write a function to generate all combinations of well-formed parentheses. For example, given n = 3, a solu

2015-12-29 08:23:29 219

原创 Valid Parentheses

每日算法——leetcode系列问题 Valid ParenthesesDifficulty: Easy Given a string containing just the characters '(', ')', '{', '}', '[' and ']', determine if the input string is valid. The brackets must clos

2015-12-28 08:32:21 195

原创 Remove Nth Node From End of List

每日算法——leetcode系列问题 Remove Nth Node From End of ListDifficulty: Easy Given a linked list, remove the nth node from the end of list and return its head. For example, Given linked list: 1->2->3-

2015-12-27 22:51:33 227

原创 Letter Combinations of a Phone Number

每日算法——leetcode系列问题 3Sum ClosestDifficulty: Medium Given a digit string, return all possible letter combinations that the number could represent. A mapping of digit to letters (just like on the t

2015-12-26 23:28:38 338

原创 3Sum Closest

每日算法——leetcode系列问题 3Sum ClosestDifficulty: Medium Given an array S of n integers, find three integers in S such that the sum is closest to a given number, target. Return the sum of the three integers

2015-12-24 07:50:04 204

原创 3Sum

每日算法——letcode系列问题 Longest Common PrefixDifficulty: Medium Given an array S of n integers, are there elements a, b, c in S such that a + b + c = 0? Find all unique triplets in the array which gives th

2015-12-23 08:37:04 238

原创 Longest Common Prefix

每日算法——letcode系列问题 Longest Common PrefixDifficulty: Easy Write a function to find the longest common prefix string amongst an array of strings.class Solution {public: string longestCommonPrefix(

2015-12-22 08:01:46 377

原创 Roman to Integer

每日算法——letcode系列问题 Roman to IntegerDifficulty: Easy Given a roman numeral, convert it to an integer. Input is guaranteed to be within the range from 1 to 3999.class Solution {public: int ro

2015-12-21 07:38:57 289

原创 String to Integer (atoi)

每日算法——letcode系列问题 String to Integer (atoi)Difficulty: Easy Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge, please do

2015-12-20 21:23:22 361

原创 Palindrome Number

每日算法——letcode系列问题 Reverse IntegerDifficulty: Easy Determine whether an integer is a palindrome. Do this without extra space. Some hints: Could negative integers be palindromes? (ie, -1)

2015-12-18 08:24:10 292

原创 Reverse Integer

每日算法——letcode系列问题 Reverse IntegerDifficulty: Easy Reverse digits of an integer. Example1: x = 123, return 321 Example2: x = -123, return -321 Have you thought about this? Here are s

2015-12-17 07:48:06 303

原创 ZigZag Conversion

每日算法——letcode系列问题 ZigZag ConversionDifficulty: Easy 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 fo

2015-12-16 20:46:36 192

原创 Median of Two Sorted Arrays

Median of Two Sorted ArraysDifficulty: HardThere are two sorted arrays nums1 and nums2 of size m and n respectively. Find the median of the two sorted arrays. The overall run time complexity should be O(log

2015-12-15 22:26:24 313

原创 Longest Substring Without Repeating Characters

每日算法——letcode系列问题 Longest Substring Without Repeating CharactersDifficulty: Medium Given a string, find the length of the longest substring without repeating characters. For example, the longest subs

2015-12-14 08:15:44 254

翻译 Add Two Numbers

每日算法——letcode系列标签: 算法 C++ LetCode问题 Add Two NumbersDifficulty: Medium You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their n

2015-12-13 10:15:46 261

翻译 Two Sum

Two Sum每日算法——letcode系列问题 Two SumDifficulty:Medium 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 th

2015-12-12 10:43:50 313

翻译 Remove Duplicates from Sorted Array II

Remove Duplicates from Sorted Array II每日算法——letcode系列问题 Remove Duplicates from Sorted Array IIDifficulty:Medium Follow up for “Remove Duplicates”: What if duplicates are allowed at most twice?

2015-12-11 08:38:46 217

翻译 #每日算法——letcode系列

问题 Remove Duplicates from Sorted ArrayDifficulty:Easy Given a sorted array, remove the duplicates in place such that each element appear only once and return the new length. Do not allocate extra

2015-12-10 08:19:48 351

The.Go.Programming.Language.2015.11

go最新书 The Go Programming Language is the authoritative resource for any programmer who wants to learn Go. It shows how to write clear and idiomatic Go to solve real-world problems. The book does not assume prior knowledge of Go nor experience with any specific language, so you’ll find it accessible whether you’re most comfortable with JavaScript, Ruby, Python, Java, or C++. The first chapter is a tutorial on the basic concepts of Go, introduced through programs for file I/O and text processing, simple graphics, and web clients and servers.

2015-12-05

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除