摘要: #include <iostream> #include <vector> #include <algorithm> using namespace std; // 自顶向下的方式 pair<int, vector<int>> maximumTotal(vector<vector<int>>& tr 阅读全文
posted @ 2025-03-16 16:41 SIPnnnnn 阅读(9) 评论(0) 推荐(0)
摘要: 1 /* 2 给定一个无序的整数数组,找到其中最长上升子序列的长度。 3 子序列是由数组派生而来的序列,删除(或不删除)数组中的元素而不改变其余元素的顺序。 4 例如,[3,6,2,7] 是数组 [0,3,1,6,2,2,7] 的一个子序列。 5 6 7 */ 8 9 #include <iostr 阅读全文
posted @ 2025-03-16 15:23 SIPnnnnn 阅读(5) 评论(0) 推荐(0)