摘要: 一、题目描述http://www.patest.cn/contests/mooc-ds2015spring/01-%E5%A4%8D%E6%9D%82%E5%BA%A61给定K个整数组成的序列{ N1, N2, ..., NK },“连续子列”被定义为{ Ni, Ni+1, ..., Nj },其中... 阅读全文
posted @ 2016-01-24 10:21 面包包包包包包 阅读(611) 评论(0) 推荐(0) 编辑
摘要: 一、题目Given two binary strings, return their sum (also a binary string).For example,a ="11"b ="1"Return"100".Subscribeto see which companies asked this ... 阅读全文
posted @ 2015-11-04 17:15 面包包包包包包 阅读(150) 评论(0) 推荐(0) 编辑
摘要: 一、题目Given a stringsconsists of upper/lower-case alphabets and empty space characters' ', return the length of last word in the string.If the last word... 阅读全文
posted @ 2015-11-03 14:30 面包包包包包包 阅读(189) 评论(0) 推荐(0) 编辑
摘要: 一、题目The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1is read off as"one 1"or11.11is read off a... 阅读全文
posted @ 2015-11-03 11:28 面包包包包包包 阅读(147) 评论(0) 推荐(0) 编辑
摘要: 一、题目Determine if a Sudoku is valid, according to:Sudoku Puzzles - The Rules.The Sudoku board could be partially filled, where empty cells are filled w... 阅读全文
posted @ 2015-10-30 18:13 面包包包包包包 阅读(679) 评论(0) 推荐(0) 编辑
摘要: 一、题目Implement strStr().Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack.二、分析很容易想出O(M*N)的算法,也很容... 阅读全文
posted @ 2015-10-28 11:05 面包包包包包包 阅读(112) 评论(0) 推荐(0) 编辑
摘要: 一、题目#27Given 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... 阅读全文
posted @ 2015-10-25 17:33 面包包包包包包 阅读(426) 评论(0) 推荐(0) 编辑
摘要: 括号匹配,栈 阅读全文
posted @ 2015-10-18 11:05 面包包包包包包 阅读(124) 评论(0) 推荐(0) 编辑
摘要: 去除LinkList中倒数第n个节点,VIM 阅读全文
posted @ 2015-09-23 14:43 面包包包包包包 阅读(123) 评论(0) 推荐(0) 编辑
摘要: 找list中是否存在a+b+c=0的三个数,若存在,找出所有可能的组合。 阅读全文
posted @ 2015-08-26 22:42 面包包包包包包 阅读(135) 评论(0) 推荐(0) 编辑