Given an unsorted array of integers, find the length of longest increasing subsequence. For example,Given [10, 9, 2, 5, 3, 7, 101, 18],The longest inc ...
分类:
其他好文 时间:
2016-08-02 13:18:43
阅读次数:
127
Given a string, find the length of the longest substring without repeating characters. Examples: Given "abcabcbb", the answer is "abc", which the leng ...
分类:
其他好文 时间:
2016-08-02 06:35:36
阅读次数:
158
原题如下: Given a string, find the length of the longest substring without repeating characters. Examples: Given "abcabcbb", the answer is "abc", which th ...
分类:
其他好文 时间:
2016-08-02 01:18:49
阅读次数:
136
Given an unsorted array of integers, find the length of longest increasing subsequence. For example, Given [10, 9, 2, 5, 3, 7, 101, 18], The longest i ...
分类:
其他好文 时间:
2016-08-01 10:24:06
阅读次数:
140
题意: Given a string, find the length of the longest substring without repeating characters. Examples: Given "abcabcbb", the answer is "abc", which the ...
分类:
其他好文 时间:
2016-07-31 20:48:21
阅读次数:
208
Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest l ...
分类:
其他好文 时间:
2016-07-31 20:36:47
阅读次数:
90
Longest Match A newly opened detective agency is struggling with their limited intelligence to find out a secret information passing technique among i ...
分类:
其他好文 时间:
2016-07-31 17:40:30
阅读次数:
189
问题链接:UVA455 Periodic Strings。入门练习题,用C语言编写程序。
题意:如果一个串可以由长度为k的字符串重复多次连接而得到,则称该串为k周期。本题求一个串的最小周期。
程序中,封装了一个函数strcmplen()用于比较相同串的两个指定长度的子串,使得主函数的逻辑变得简单。
另外,输出格式上需要注意。题中有“Two consecutive output are sep...
分类:
其他好文 时间:
2016-07-31 15:59:49
阅读次数:
127
大晚上的更一道下午的水题吧。(虽然WA了好多次= =,但真实情况是我比较水) 描述 Given a sequence, you're asked whether there exists a consecutive subsequence whose sum is divisible by m. o ...
分类:
其他好文 时间:
2016-07-31 01:41:42
阅读次数:
185