11 2015 档案

摘要:public static void Lcs_Length(String X,String Y,int c[][]) { X=" "+X; Y=" "+Y; for(int i=1;i=c[i][j-1]) { c[i][j]=c[i-1][j]; } else ... 阅读全文
posted @ 2015-11-21 00:15 liuhg 阅读(438) 评论(0) 推荐(0)
摘要:public static int Fib(int n) { int q=0; int []r=new int[n+1]; r[0]=1; r[1]=1; for(int j=2;j<=n;j++) {... 阅读全文
posted @ 2015-11-16 23:30 liuhg 阅读(184) 评论(0) 推荐(0)
摘要:public class CUTROD{ //1.自顶向下 public static int Memoized_Cut_Rod(int []p,int n) { int r[]=new int[n+1]; for(int i=0;i=0) ... 阅读全文
posted @ 2015-11-15 23:22 liuhg 阅读(188) 评论(0) 推荐(0)