摘要: Implement strStr().Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack. Update (2014-11-02):The s... 阅读全文
posted @ 2015-01-04 07:08 LiBlog 阅读(179) 评论(0) 推荐(0) 编辑
摘要: Given an absolute path for a file (Unix-style), simplify it.For example,path = "/home/", => "/home"path = "/a/./b/../../c/", => "/c"click to show corn... 阅读全文
posted @ 2015-01-04 06:01 LiBlog 阅读(148) 评论(0) 推荐(0) 编辑
摘要: Given an unsorted array, find the maximum difference between the successive elements in its sorted form.Try to solve it in linear time/space.Return 0 ... 阅读全文
posted @ 2015-01-04 05:27 LiBlog 阅读(245) 评论(0) 推荐(0) 编辑