摘要:
标签(空格分隔): 数位DP 二分 "题目链接" 先算出答案1的个数,再二分查找 阅读全文
摘要:
标签(空格分隔): 数位DP "题目链接" 枚举作为枢纽的点,注意零的情况 cpp include include include using namespace std; typedef long long ll; ll read() { ll x=0,f=1;char ch=getchar(); 阅读全文
摘要:
标签(空格分隔): 数位DP "题目链接" 记录一下相邻位置的数字,前导零特殊处理 阅读全文
摘要:
标签(空格分隔): 数位DP "题目链接" 将ABCD拆成二进制位,则对于一个不等式,差大于2时一定成立,小于 2时一定不成立 cpp include include include using namespace std; typedef long long ll; ll read() { ll 阅读全文
摘要:
标签(空格分隔): 数位DP 背包DP 算出有i个幸运数字的方案,然后枚举上限做背包DP cpp include include include using namespace std; typedef long long ll; ll read() { ll x=0,f=1;char ch=get 阅读全文
摘要:
标签(空格分隔): 数位DP "题目链接" 开始递增后就不能递减了 cpp include include include using namespace std; typedef long long ll; ll read() { ll x=0,f=1;char ch=getchar(); whi 阅读全文
摘要:
标签(空格分隔): 数位DP "题目链接" 枚举第一位不为零的数 cpp include include include using namespace std; typedef long long ll; ll read() { ll x=0,f=1;char ch=getchar(); whil 阅读全文
摘要:
标签(空格分隔): 数位DP "题目链接" cpp include include include using namespace std; typedef long long ll; ll read() { ll x=0,f=1;char ch=getchar(); while(ch'9'){if 阅读全文
摘要:
标签(空格分隔): 数位DP "題目链接" DP 显然每一位只有选一或选0的情况 cpp include include include using namespace std; typedef long long ll; ll read() { ll x=0,f=1;char ch=getchar 阅读全文