题目描述:
Given a string s consists of upper/lower-case alphabets and empty space characters '
', return the length of last word in the string.
If the last word does not exist, return 0.
Note...
分类:
其他好文 时间:
2015-04-16 12:34:04
阅读次数:
110
Given a stringsconsists of upper/lower-case alphabets and empty space characters' ', return the length of last word in the string.If the last word doe...
分类:
其他好文 时间:
2015-04-12 06:43:40
阅读次数:
113
Given an array of strings, return all groups of strings that are anagrams.Note: All inputs will be in lower-case.solution:直接乘会超时~~所以只能用递归~~public clas...
分类:
其他好文 时间:
2015-04-11 07:50:41
阅读次数:
132
标题:Anagrams通过率:24.3%难度:中等Given an array of strings, return all groups of strings that are anagrams.Note: All inputs will be in lower-case.leetcode没有表述...
分类:
其他好文 时间:
2015-04-10 11:10:26
阅读次数:
116
Problem Description
035 now faced a tough problem,his english teacher gives him a string,which consists with n lower case letter,he must figure out how many substrings appear at least twice,moreover,s...
分类:
编程语言 时间:
2015-04-09 15:34:55
阅读次数:
213
题目:
Given an array of strings, return all groups of strings that are anagrams.
Note: All inputs will be in lower-case.
思路:
判断两个字符串是否为anagram的方法可以有:
1)将每个字符串的所有字符按字典序排列,比较是否相同。
2)用Has...
分类:
其他好文 时间:
2015-04-08 15:02:39
阅读次数:
143
大小写转换/** * 对关联数组中键名转换大小写处理 * @param [type] $arr 要转换的数组 * @param string $op 必须是CASE_LOWER,CASE_UPPER其中的值,忽略大小写,默认为CASE_LOWER * @return [type] 转...
分类:
其他好文 时间:
2015-04-08 14:37:10
阅读次数:
127
Given a string which contains only letters. Sort it by lower case first and upper case second.NoteIt's not necessary to keep the original order of low...
分类:
其他好文 时间:
2015-04-06 10:04:22
阅读次数:
225
Length of Last Word
Given a string s consists of upper/lower-case alphabets and empty space characters '
', return the length of last word in the string.
If the last word does not exist, ret...
分类:
其他好文 时间:
2015-04-05 14:39:14
阅读次数:
107
Given an array of strings, return all groups of strings that are anagrams.Note: All inputs will be in lower-case.http://www.cnblogs.com/AnnieKim/archi...
分类:
其他好文 时间:
2015-04-02 06:37:46
阅读次数:
113