上一页 1 ··· 15 16 17 18 19 20 21 22 23 ··· 28 下一页

2015年5月10日

摘要: 题目:Write a function to find the longest common prefix string amongst an array of strings.代码:class Solution {public: string longestCommonPrefix(vect... 阅读全文
posted @ 2015-05-10 18:22 承续缘 阅读(182) 评论(0) 推荐(0) 编辑

2015年5月8日

摘要: 题目:Implement wildcard pattern matching with support for'?'and'*'.'?' Matches any single character.'*' Matches any sequence of characters (including th... 阅读全文
posted @ 2015-05-08 09:53 承续缘 阅读(268) 评论(0) 推荐(0) 编辑

2015年5月7日

摘要: 题目:Implement regular expression matching with support for'.'and'*'.'.' Matches any single character.'*' Matches zero or more of the preceding element.... 阅读全文
posted @ 2015-05-07 11:17 承续缘 阅读(223) 评论(0) 推荐(0) 编辑

2015年5月6日

摘要: 题目:Given a stringS, find the longest palindromic substring inS. You may assume that the maximum length ofSis 1000, and there exists one unique longest... 阅读全文
posted @ 2015-05-06 16:03 承续缘 阅读(204) 评论(0) 推荐(0) 编辑
摘要: 题目:Given two binary strings, return their sum (also a binary string).For example,a ="11"b ="1"Return"100".代码:class Solution {public: string addBina... 阅读全文
posted @ 2015-05-06 10:05 承续缘 阅读(204) 评论(0) 推荐(0) 编辑

2015年5月5日

摘要: 题目:Implementatoito convert a string to an integer.Hint:Carefully consider all possible input cases. If you want a challenge, please do not see below a... 阅读全文
posted @ 2015-05-05 20:31 承续缘 阅读(346) 评论(0) 推荐(0) 编辑

2015年5月3日

摘要: 题目: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... 阅读全文
posted @ 2015-05-03 22:30 承续缘 阅读(235) 评论(0) 推荐(0) 编辑
摘要: 题目:Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases.For example,"A man, a plan, a canal: P... 阅读全文
posted @ 2015-05-03 22:24 承续缘 阅读(173) 评论(0) 推荐(0) 编辑

2015年5月1日

摘要: 题目:Design and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations:getandset.get(key)- Get the v... 阅读全文
posted @ 2015-05-01 21:57 承续缘 阅读(233) 评论(0) 推荐(0) 编辑
摘要: 题目:Given a singly linked listL:L0→L1→…→Ln-1→Ln,reorder it to:L0→Ln→L1→Ln-1→L2→Ln-2→…You must do this in-place without altering the nodes' values.For e... 阅读全文
posted @ 2015-05-01 09:42 承续缘 阅读(172) 评论(0) 推荐(0) 编辑
上一页 1 ··· 15 16 17 18 19 20 21 22 23 ··· 28 下一页

导航