声明一个注解 @Target({ElementType.METHOD}) @Retention(RetentionPolicy.RUNTIME) @Documented@Order(Ordered.HIGHEST_PRECEDENCE)public @interface RequestLimit { ...
                            
                            
                                分类:
编程语言   时间:
2018-03-21 16:36:38   
                                阅读次数:
370
                             
                    
                        
                            
                            
                                    题目中文:求最长回文子串 题目难度:Medium 题目内容: Given a string s, find the longest palindromic substring in s. You may assume that the maximum length of s is 1000. 翻译: ...
                            
                            
                                分类:
编程语言   时间:
2018-03-19 19:09:23   
                                阅读次数:
224
                             
                    
                        
                            
                            
                                    题目描述 设G为有n个顶点的有向无环图,G中各顶点的编号为1到n,且当为G中的一条边时有i < j。设w(i,j)为边的长度,请设计算法,计算图G中<1,n>间的最长路径。 输入输出格式 输入格式: 输入文件longest.in的第一行有两个整数n和m,表示有n个顶点和m条边,接下来m行中每行输入3 ...
                            
                            
                                分类:
其他好文   时间:
2018-03-14 22:39:11   
                                阅读次数:
220
                             
                    
                        
                            
                            
                                    Description: Given a string, find the length of the longest substring without repeating characters. 题意: 输入一个字符串, 输出最长不重复子串的长度 思路: 比较一般的思路是, 只要是有关于重复的应 ...
                            
                            
                                分类:
其他好文   时间:
2018-03-12 22:54:30   
                                阅读次数:
211
                             
                    
                        
                            
                            
                                def longestCommonSubstring(self, A, B): # write your code here if A == '' or B == '': return 0 if len(A) >= len(B): L, L1 = A[:], B[:] else: L, L... ...
                            
                            
                                分类:
其他好文   时间:
2018-03-11 17:41:51   
                                阅读次数:
109
                             
                    
                        
                            
                            
                                在linux里,source、sh、bash、./都可以执行shell script文件,那它们有什么不同吗? 1、source 在当前shell内去读取、执行a.sh,而a.sh不需要有"执行权限" source命令可以简写为"." 注意:中间是有空格的。 2、sh/bash 都是打开一个subs ...
                            
                            
                                分类:
系统相关   时间:
2018-03-11 14:34:31   
                                阅读次数:
214
                             
                    
                        
                            
                            
                                Given a string, find the length of the longest substring T that contains at most k distinct characters. For example, Given s = “eceba” and k = 2, T is ...
                            
                            
                                分类:
其他好文   时间:
2018-03-10 10:19:58   
                                阅读次数:
246
                             
                    
                        
                            
                            
                                    问题链接 "LeetCode 3" 题目解析 求字符串的 最长无重复子串 。 解题思路 第一个问题是 子串 ,注意是连续的。 建立一个符号哈希数组 $in[256]$,代表该符号时候出现过,256大小是因为ASCII表共能表示256个字符。初始化为0,代表未出现,当 $in[i] 0$ 时,表示该字 ...
                            
                            
                                分类:
其他好文   时间:
2018-03-09 20:37:22   
                                阅读次数:
279
                             
                    
                        
                            
                            
                                    http://www.spoj.com/problems/LCS2/ 题意: 求10个串的LCS 1、用第一个串建立后缀自动机 2、len[s] 表示状态s 所能代表的字符串的最大长度 mx[s] 表示状态s 在 当前匹配的串的最长匹配后缀长度 ans[s] 表示状态s 在所有串的最长匹配后缀长度  ...
                            
                            
                                分类:
其他好文   时间:
2018-03-08 22:03:39   
                                阅读次数:
226
                             
                    
                        
                            
                            
                                    题目中文:没有重复字符的最长子串 题目难度:Medium 题目内容: Given a string, find the length of the longest substring without repeating characters. Examples: Given "abcabcbb",  ...
                            
                            
                                分类:
编程语言   时间:
2018-03-08 18:09:56   
                                阅读次数:
141