摘要: 描述Given a string s consists of upper/lower-case alphabets and empty space characters ' ', return thelength of last word in the string.If the last word 阅读全文
posted @ 2018-07-03 23:54 昵称真难想 阅读(85) 评论(0) 推荐(0) 编辑
摘要: 描述Given an absolute path for a file (Unix-style), simplify it.For example,path = "/home/", => "/home"path = "/a/./b/../../c/", => "/c"Corner Cases:• D 阅读全文
posted @ 2018-07-03 23:12 昵称真难想 阅读(118) 评论(0) 推荐(0) 编辑
摘要: 描述Given an array of strings, return all groups of strings that are anagrams.Note: All inputs will be in lower-case.分析Anagram(回文构词法)是指打乱字母顺序从而得到新的单词,比如 阅读全文
posted @ 2018-07-03 21:58 昵称真难想 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 描述The count-and-say sequence is the sequence of integers beginning as follows:1, 11, 21, 1211, 111221, ...1 is read off as "one 1" or 11.11 is read of 阅读全文
posted @ 2018-07-03 10:51 昵称真难想 阅读(172) 评论(0) 推荐(0) 编辑