
尺取法 反转法
# 尺取法 反转法
OPA_heiyaa
嗨嗨嗨
展开
-
POJ--3061--尺取法
A sequence of N positive integers (10 < N < 100 000), each of them less than or equal 10000, and a positive integer S (S < 100 000 000) are given. Write a program to find the minimal length o...原创 2020-02-02 10:57:52 · 301 阅读 · 0 评论 -
最长上升子序列
直接上模板: int dp[MAX]; void solve(){ memset(dp,INF,sizeof(dp)); for(int i=0;i<n;i++) *lower_bound(dp,dp+n,a[i])=a[i]; printf("%d\n",lower_bound(dp,dp+n,INF)-dp);//这里不用添加* } ...原创 2020-02-02 10:25:57 · 152 阅读 · 0 评论