totaled
totaled
全部文章
分类
atcoder(1)
codeforces(6)
leetcode(17)
Linux(5)
操作系统(2)
数据结构(7)
未归档(1)
算法(23)
网络编程(1)
计算机网络(5)
题解(84)
归档
标签
去牛客网
登录
/
注册
qin_peng
O_O
TA的专栏
10篇文章
0人订阅
Hello Code
10篇文章
8715人学习
全部文章
(共9篇)
牛客练习赛-反演、差分
题目链接 枚举因子如果,那么在这个区间内都有贡献,即这个区间都加上这个贡献,显然用差分解决。 #include<bits/stdc++.h> using namespace std; #define me(a,x) memset(a,x,sizeof(a)) #define s...
狄利克雷卷积
莫比乌斯反演
2021-01-27
2
594
Dirichlet求和
求出的话一般是的复杂度。可以转移质因子的贡献,优化到的复杂度。 前缀和 知道求 for(int i=1;i<=cnt&&pri[i]<=n;i++){ for(int j=1;j*pri[i]<=n;i++){ a[j * pri[i]] ...
狄利克雷卷积
2021-01-27
0
599
牛客F-解方程(狄利克雷卷积)
package main import ( "bufio" "fmt" "os" "sync" ) func min(a, b int) int { if a < b { return a } return b } ...
狄利克雷卷积
2020-09-12
2
687
HDU-6063 RXD and math
HDU-6063 RXD and math
狄利克雷卷积
莫比乌斯反演
积性函数
2020-02-15
0
444
2020 Wannafly Day3 D.求和(反演,杜教筛)
求和 #include<bits/stdc++.h> using namespace std; typedef long long ll; ll mod; const int N=1e6+6; bool vis[N]; ll prime[N],phi[N],tot; ll...
狄利克雷卷积
莫比乌斯反演
杜教筛
2020-01-29
0
650
2019 ICPC-EC final C.Dirichlet k -th root
C.Dirichlet k -th root 狄利克雷卷积性质,和HDU-5628 Clarke and math这题一样。 复杂度. #include<bits/stdc++.h> using namespace std; const int mod=998244353; ...
狄利克雷卷积
2020-01-12
2
1927
积性函数、狄利克雷卷积的一些结论
莫比乌斯函数,欧拉函数,,,,。 为的不同素因子个数,为的所有素因子个数。。
狄利克雷卷积
莫比乌斯反演
欧拉函数
积性函数
2019-12-02
0
819
HDU-5382 GCD?LCM!(反演)
HDU-5382 GCD?LCM! #include<bits/stdc++.h> #define sc scanf using namespace std; const int N=1e6+77; const int mod=258280327; typedef long...
狄利克雷卷积
莫比乌斯反演
2019-09-26
0
684
HDU-5628 Clarke and math
HDU-5628 Clarke and math . #include<bits/stdc++.h> #define me(a,x) memset(a,x,sizeof(a)) #define IN freopen("in.txt","r",stdin); #define...
狄利克雷卷积
积性函数
2019-09-25
1
957