shyyhs
shyyhs
全部文章
题解
DP专题(52)
图论(4)
多校补题(2)
数据结构(27)
数论(4)
日记(14)
未归档(38)
归档
标签
去牛客网
登录
/
注册
shyyhs的博客
全部文章
/ 题解
(共329篇)
acwing 278题解
来自专栏
具体b站 #include <bits/stdc++.h> using namespace std; const int N=1e5+5; int a[105]; int f[N]; int main() { int n,m; cin>>n>>m;...
dp
2020-06-18
1
656
acwing 271题解
来自专栏
具体b站: #include <bits/stdc++.h> using namespace std; typedef long long ll; const ll N=32; ll dp[N][N][N][N][N]; int s[7]; int main() { int k;...
dp
2020-06-18
1
658
acwing 206题解
来自专栏
具体b站有. #include <bits/stdc++.h> using namespace std; typedef long long ll; const int N=65; int n,m,t,acts;//代表n行m列.t时间,act个操作 string ops[10]; st...
矩阵快速幂
2020-06-18
1
564
acwing 205题解
来自专栏
具体讲解b站有. #include <bits/stdc++.h> using namespace std; const int mod=10000; void mul1(int f[2],int a[2][2]) { int temp[2]={0}; for(int i...
矩阵快速幂
2020-06-18
1
675
acwing 272题解
来自专栏
这题思路比较简单,提前是你得设出来状态. dp(i,j)表示以1~j以b[j]结尾最长公共上升子序列. 转移的条件肯定是a[i]==b[j]. 假如a[i]!=b[j].假如我现在的a[i]<b[j]那么这个a[i]一定不能通过bj转移.因为不满足递增. 假如a[i]>b[j]那么我的a...
dp
2020-06-18
1
656
Animal Protection题解
来自专栏
这个主要是为了收获更多粉丝,我会认真的讲下单调栈和如何处理这个问题的...下面贴上ac代码: #include <bits/stdc++.h> using namespace std; typedef long long ll; const ll mod=1000000007; cons...
单调栈
2020-06-15
3
668
acwing 203题解
来自专栏
#include <bits/stdc++.h> using namespace std; int x,y; void ex_gcd(int a,int b) { if(b==0) { x=1,y=0; return; } ...
exgcd
2020-06-14
2
574
acwing 202题解
来自专栏
代码: #include <bits/stdc++.h> using namespace std; typedef long long ll; inline ll ksc(ll x,ll y,ll p) { ll res=0;while(y){if(y&1)res=(re...
数论
2020-06-13
1
662
acwing 201题解
来自专栏
代码: #include <bits/stdc++.h> using namespace std; const int N=1005; int prime[N],cnt=0,f[N],sum[N]; bool st[N]; void init() { f[1]=1; f...
欧拉函数
2020-06-13
1
712
acwing 200题解
来自专栏
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<ll,ll> pi; const ll M=1e5; const ll N=2e3; bool st[M+5]; ...
数学
2020-06-13
1
728
首页
上一页
23
24
25
26
27
28
29
30
31
32
下一页
末页