随笔分类 -  算法:dp > dp优化

摘要:books servers watchmen prison swaps xanadu \(\color{green}{\texttt{+8}}\) \(\color{green}{\texttt{+2}}\) \(\color{green}{\texttt{-}}\) \(\color{green} 阅读全文
posted @ 2021-10-31 19:09 Flying2018 阅读(73) 评论(0) 推荐(0) 编辑
摘要:链接 A. Bear and Colors 水题,直接扫两遍就好了 B. Bear and Two Paths 构造题。考虑 \(m=n\) 是一个环凑一凑发现不合法。所以一定是 \(m=n+1\)。 可以发现只要 \(n>4\) 一定可以放两个三元环,否则无解。 C. Levels and Reg 阅读全文
posted @ 2021-10-11 19:16 Flying2018 编辑
该文被密码保护。
posted @ 2021-05-07 20:51 Flying2018 编辑
摘要:wqs二分&闵可夫斯基和学习笔记 阅读全文
posted @ 2021-04-27 21:27 Flying2018 阅读(2371) 评论(0) 推荐(16) 编辑
摘要:毒瘤题 阅读全文
posted @ 2020-11-24 20:43 Flying2018 阅读(395) 评论(0) 推荐(0) 编辑
摘要:毒瘤题 阅读全文
posted @ 2020-10-28 10:47 Flying2018 阅读(239) 评论(2) 推荐(3) 编辑
摘要:链接 题目大意 给定一个 \(n\times m\) 的矩阵。 定义一个矩阵的元素如果全部相等那么他的“混乱度”为0。否则你可以用一条直线将其分为两个子矩阵,混乱度为两个子矩阵的混乱度较大值+1。 \(n\leq 185\) 题解 首先显然有一个 \(O(n^4\log n)\) 的dp:令 \(f 阅读全文
posted @ 2020-10-27 10:14 Flying2018 阅读(144) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示