题目:
Given a string containing just the characters '(' and ')',
find the length of the longest valid (well-formed) parentheses substring.
For "(()", the longest valid parentheses substring is...
分类:
编程语言 时间:
2015-07-12 12:55:23
阅读次数:
140
??1 Broadcast是Android中的四大组件之一,他的用途很大,比如系统的一些广播:电量低、开机、锁屏等一些操作都会发送一个广播。2 广播被分为两种不同的类型:“普通广播(Normalbroadcasts)”和“有序广播(Ordered broadcasts)”.普通广播是完全异步的,可以在同一时刻(逻辑上)被所有广播接收者接收到,消息传递的效率比较高,但缺点是:接收者不能将处理结果...
分类:
移动开发 时间:
2015-07-12 00:22:15
阅读次数:
1104
Problem:Write a function to find the longest common prefix string amongst an array of strings.Solution:题意要求求取字符串数组的最长公共前缀子串。从位置0开始,对每一个位置比较所有的字符串,直到遇到...
分类:
其他好文 时间:
2015-07-11 20:09:04
阅读次数:
134
Given a string S, find the longest palindromic substring in S. You may assume that the maximum length of S is 1000, and there exists one unique longes...
分类:
其他好文 时间:
2015-07-11 09:00:02
阅读次数:
101
Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters fo...
分类:
其他好文 时间:
2015-07-11 06:43:10
阅读次数:
124
Maximum Depth of Binary Tree (DFS, TREE)Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path fr...
分类:
其他好文 时间:
2015-07-10 13:17:22
阅读次数:
99
3 Longest Substring Without Repeating Characters链接:https://leetcode.com/problems/longest-substring-without-repeating-characters/
问题描述:
Given a string, find the length of the longest substring withou...
分类:
其他好文 时间:
2015-07-10 09:34:17
阅读次数:
134
1 class Solution { 2 public: 3 int lengthOfLongestSubstring(string s) { 4 int len = s.length(), m = 0, l = 0, p[256] = { 0 }; 5 f...
分类:
编程语言 时间:
2015-07-10 02:11:53
阅读次数:
139
二叉查找树(Binary Search Tree),也称有序二叉树(ordered binary tree),排序二叉树(sorted binary tree),是指一棵空树或者具有下列性质的二叉树:1. 若任意节点的左子树不空,则左子树上所有结点的值均小于它的根结点的值;2. 若任意节点的右子树不...
分类:
编程语言 时间:
2015-07-10 00:07:29
阅读次数:
230
Given a string containing just the characters'('and')', find the length of the longest valid (well-formed) parentheses substring.For"(()", the longest...
分类:
其他好文 时间:
2015-07-09 17:29:41
阅读次数:
106