摘要: 水了一个环形均分纸牌的问题: 叫七夕祭: 原题链接 这个题就是一个裸的环形均分纸牌问题 用到的性质每个数到中位数距离之和是最短的。 code: #include <iostream> #include <cstring> #include <string> #include <algorithm> 阅读全文
posted @ 2020-03-05 16:29 kstranger 阅读(257) 评论(0) 推荐(0)
摘要: 这个题和最长上升子序列都是一个类型的题 题意是求一个序列的最长上升子序列的长度 输入数据是: 28100 287 155 300 299 178 158 65388 23 65 输出是: 52 是序列dp的入门题 代码: #include <iostream> #include <cstring> 阅读全文
posted @ 2020-03-05 16:25 kstranger 阅读(1428) 评论(0) 推荐(0)