摘要: github偶尔上不去,把学长给我们的学习资源转载在这里,同时记录下自己的学习感悟。Lesson 1:html 基本标签Lesson 2: html语义化 html4 html5 xhtml区别Lesson 3: html编码标准,百度教育页面html分析Lesson 4:http://www.w3... 阅读全文
posted @ 2014-04-28 20:18 果汁果粒 阅读(147) 评论(0) 推荐(0) 编辑
摘要: public class Solution { public int maxDepth(TreeNode root) { int count = 0; if(root==null) count = 0; else if(root.... 阅读全文
posted @ 2014-04-15 11:18 果汁果粒 阅读(112) 评论(0) 推荐(0) 编辑
摘要: 这一放,居然放了一个多月,上一题是11月3日的19.Remove Nth Node From End of List今天已经12月12日了,真是时不我待!原来不被管束已经一个多月了,我也是如此不自觉。想想如果这段时间我坚持每天做一题,现在的题号就是19+38=57了。。。题目:Mergeksorted linked lists and return it as one sorted list. Analyze and describe its complexity.题解:(解法一)忘记是不是做过Merge2sorted linked lists 了,这题用之前Pin给我看的那篇简而化之的文章应 阅读全文
posted @ 2013-12-12 15:46 果汁果粒 阅读(184) 评论(0) 推荐(0) 编辑
摘要: ggg 阅读全文
posted @ 2013-11-25 17:17 果汁果粒 阅读(140) 评论(0) 推荐(0) 编辑
摘要: Given a linked list, remove thenthnode from the end of list and return its head.For example, Given linked list: 1->2->3->4->5, and n = 2. After removing the second node from the end, the linked list becomes 1->2->3->5.Note:Givennwill always be valid.Try to do this in one pass.用双 阅读全文
posted @ 2013-11-03 22:16 果汁果粒 阅读(146) 评论(0) 推荐(0) 编辑
摘要: Given a digit string, return all possible letter combinations that the number could represent.A mapping of digit to letters (just like on the telephone buttons) is given below.Input:Digit string "23"Output: ["ad", "ae", "af", "bd", "be", &q 阅读全文
posted @ 2013-11-01 15:37 果汁果粒 阅读(176) 评论(0) 推荐(0) 编辑
摘要: Given an arraySofnintegers, find three integers inSsuch that the sum is closest to a given number, target. Return the sum of the three integers. You may assume that each input would have exactly one solution. For example, given array S = {-1 2 1 -4}, and target = 1. The sum that is closest to ... 阅读全文
posted @ 2013-11-01 10:50 果汁果粒 阅读(195) 评论(0) 推荐(0) 编辑
摘要: Given an arraySofnintegers, are there elementsa,b,cinSsuch thata+b+c= 0? Find all unique triplets in the array which gives the sum of zero.Note:Elements in a triplet (a,b,c) must be in non-descending order. (ie,a≤b≤c)The solution set must not contain duplicate triplets.For example, given array S = { 阅读全文
posted @ 2013-10-30 22:20 果汁果粒 阅读(185) 评论(0) 推荐(0) 编辑
摘要: Write a function to find the longest common prefix string amongst an array of strings.从字符数组的第一项往后挨个比较。第一次比较后,取第一项与第二项共同的前缀与第三项比较,依此类推。public class Solution { public String longestCommonPrefix(String[] strs) { // IMPORTANT: Please reset any member data you declared, as // the same So... 阅读全文
posted @ 2013-10-29 22:36 果汁果粒 阅读(182) 评论(0) 推荐(0) 编辑
摘要: Givennnon-negative integersa1,a2, ...,an, where each represents a point at coordinate (i,ai).nvertical lines are drawn such that the two endpoints of lineiis at (i,ai) and (i, 0). Find two lines, which together with x-axis forms a container, such that the container contains the most water.Note: You 阅读全文
posted @ 2013-10-26 16:11 果汁果粒 阅读(224) 评论(0) 推荐(0) 编辑