摘要: http://poj.org/problem?id=1836求两遍最长上升子序列,顺序求一遍,逆序求一遍。 1 #include 2 #include 3 const int N=1002; 4 int dp1[N],dp2[N]; 5 double a[N]; 6 int main() 7 { 8 int n; 9 scanf("%d",&n);10 for (int i = 1; i a[j])21 {22 if (temp 0; i--)30 {31 int temp = 0... 阅读全文
posted @ 2014-01-18 20:23 N_ll 阅读(150) 评论(0) 推荐(0)
摘要: http://poj.org/problem?id=1080 1 #include 2 #include 3 #include 4 #include 5 using namespace std; 6 7 const int INF=1<<28; 8 int score[220][220]; 9 void init()10 {11 score['A']['C']=score['C']['A']=-1;12 score['A']['G']=score['G']['A& 阅读全文
posted @ 2014-01-18 19:16 N_ll 阅读(164) 评论(0) 推荐(0)