580A - Kefa and First Steps 思路:dp dp[i]表示包括前i个元素中a[i]在内的最大增序列. 代码: #include<bits/stdc++.h> using namespace std; ; int a[N]; int dp[N]; int main() { ios::sync_with_stdio(false); cin.tie(); int n; cin>>n; dp[]=; ; ;i<n;i++)cin>>a[i]; ;i…
580A. Kefa and First Steps 题目链接: A. Kefa and First Steps 题意描述: 给出一个序列,求最长不降连续子序列多长? 解题思路: 水题,签到 代码: #include <cstdio> #include <cstring> #include <iostream> #include <algorithm> using namespace std; int main () { int e, s, num, n,…