随笔分类 - 多项式—FWT
摘要:题意 "题目链接" Sol "挂一个讲的看起来比较好的链接" 然鹅我最后一步还是没看懂qwq。。 坐等 S ovietPower 大佬发博客 cpp include using namespace std; const int MAXN = (1 '9') {if(c == ' ') f = 1;
阅读全文
摘要:题意 "题目链接" Sol 神仙题Orzzzz 题目可以转化为从$\leqslant M$的质数中选出$N$个$xor$和为$0$的方案数 这样就好做多了 设$f(x) = [x \text{是质数}]$ $n$次异或FWT即可 快速幂优化一下,中间不用IFWT,最后转一次就行(~~然而并不知道为什
阅读全文
摘要:题意 "题目链接" Sol 背板子背板子 cpp include using namespace std; const int MAXN = (1 '9') {if(c == ' ') f = 1; c = getchar();} while(c = '0' && c = mod ? x + y m
阅读全文