摘要: 紫书:#include #include #include #include using namespace std; const int maxn = 1000; struct bign{ int d[maxn], len; ... 阅读全文
posted @ 2018-02-21 18:45 Menteur_hxy 阅读(125) 评论(0) 推荐(0) 编辑
摘要: 1.最长上升子序列(LIS)子序列: 1.可以不连续 2.相对位置不变 dp[i][j] 表示前i位置,最大值为j的LIS长度 1. dp[i-1][j] 前i-1位置,最大值为j的LIS长度 (没有考虑a[i]) 2. dp[i][j]=dp[i-1][k]+1 ... 阅读全文
posted @ 2018-02-21 18:27 Menteur_hxy 阅读(266) 评论(0) 推荐(0) 编辑