随笔分类 -  搜索

摘要:11.23 t1 chess——记搜dp 状态设错了,就靠着$0$骗分了 #include <cstring> #include <iostream> #include <algorithm> using namespace std; typedef long long ll; const int 阅读全文
posted @ 2020-11-23 14:57 ke_xin 阅读(81) 评论(1) 推荐(0)
摘要:(2)搜索 题目链接https://blog.csdn.net/ayf1988/article/details/101418391 #include <cstdio> #include <cstring> #include <iostream> #include <algorithm> using 阅读全文
posted @ 2020-10-08 17:01 ke_xin 阅读(56) 评论(0) 推荐(0)
摘要:折半爆搜 千篇一律 基本数据范围在 \(n<=40\) 然后要搜索所有集合状态, 折半爆搜即搜前一半,再搜后一半(顺便统计答案)总复杂度由$O(2^{40})$降到 \(O(2^{20})\) Incredible Cows 把$n$数分成两堆,使得两堆和的差最小。 #include<cstdio> 阅读全文
posted @ 2020-09-09 19:38 ke_xin 阅读(139) 评论(0) 推荐(0)