摘要:
Question:Given intergers A1,A2,…,An,find the maximum Subsequence Sum ProblemSolution:有很多方法可以解决这个问题。下面我只给出我认为最好的算法。 1 //linear-time maximum contiguous ... 阅读全文
摘要:
Question:computing the greatest common divisorSolution: 1 template 2 T gcd(T m,T n) 3 { 4 if(m<n) 5 { 6 T temp = a; 7 a=b;... 阅读全文