摘要:
Best 做法:不用Extra Space, Time Complexity still O(N^2) Good syntax: // creating Arrays of String type String a[] = new String[] { "A", "B", "C", "D" }; / 阅读全文
摘要:
想法是建立一个2维的boolean数组,booleen[][] check = new boolean[s.length()+1][p.length()+1],注意最好比string的length大一行和一列,来包括第0行和第0列的情况。这样初始化比较方便。check[m][n]表示s的前m个元素是 阅读全文
摘要:
Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation is counted as 1 step.)You have t... 阅读全文