裸的LIS。
代码:
dp水题,方程秒出了= =
方程:
f[i]=max{f[j]} (1<=j<i&&r[j]<l[i])
不过是\(O(n^2)\)的,好虚啊,但它应该满足决策单调性。
直接贴代码:
Host by is-Programmer.com | Power by Chito 1.3.3 beta | Theme: Aeros 2.0 by TheBuckmaker.com