@@ -0,0 +1,654 @@
+public class Solution %7B%0A    /**%0A     * @param A: A string%0A     * @param B: A string%0A     * @return: The length of longest common subsequence of A and B%0A     */%0A    public int longestCommonSubsequence(String A, String B) %7B%0A        // write your code here%0A        int n = A.length();%0A        int m = B.length();%0A        int f%5B%5D%5B%5D = new int%5Bn + 1%5D%5Bm + 1%5D;%0A        for(int i = 1; i %3C= n; i++)%7B%0A            for(int j = 1; j %3C= m; j++)%7B%0A                f%5Bi%5D%5Bj%5D = Math.max(f%5Bi - 1%5D%5Bj%5D, f%5Bi%5D%5Bj - 1%5D);%0A                if(A.charAt(i - 1) == B.charAt(j - 1))%0A                    f%5Bi%5D%5Bj%5D = f%5Bi - 1%5D%5Bj - 1%5D + 1;%0A            %7D%0A        %7D%0A        return f%5Bn%5D%5Bm%5D;%0A    %7D%0A%7D

add 77