LeetCode140:单词拆分ii

直接在leetcode上作的,牛客上把词典wordDict改为了哈希表,懒得改了,牛客上的就没写。html 思路:app table[i][j]表明从字符串s的i到j位置([i,j])是否能为一个词典中的单词,为1表示能够,为0表示不行。post e.g.测试 s:pineapplepenapple wordDict = ["apple", "pen", "applepen", "pine", "
相关文章
相关标签/搜索