- 博客(793)
- 收藏
- 关注
原创 Codeforces Round #651 (Div. 2)(A,B,C,D,E)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,mid,rt<<1#define rson mid+1,r,rt<<1|1#defin.
2020-06-26 09:31:38 267
原创 Codeforces Round #646 (Div. 2) F Rotating Substrings(思维DP)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,mid,rt<<1#define rson mid+1,r,rt<<1|1#defin.
2020-06-14 15:59:40 250
原创 Codeforces Round #646 (Div. 2) E. Tree Shuffling
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,mid,rt<<1#define rson mid+1,r,rt<<1|1#defin.
2020-06-12 11:19:27 223
原创 Codeforces Round #648 (Div. 2) (A,B,C,D,E,F)
A#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,mid,rt<<1#define rson mid+1,r,rt<<1|1#de
2020-06-10 11:21:01 192
原创 Educational Codeforces Round 86 (Rated for Div. 2) D. Multiple Testcases(思维)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,mid,rt<<1#define rson mid+1,r,rt<<1|1#defin.
2020-05-31 14:31:14 133
原创 P2444 [POI2000]病毒(AC自动机模板+)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-28 11:40:04 169
原创 CodeForces 454D Little Pony and Harmony Chest (状压DP+估界)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-26 07:46:46 151
原创 CodeForces 315E Sereja and Subsequences (权值线段树+DP)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-25 22:46:27 140
原创 CodeForces 315D Sereja and Periods (思维DP)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-25 07:59:31 185
原创 P5357 【模板】AC自动机(二次加强版)(树上差分+AC自动机)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-24 20:53:57 194
原创 P3796 【模板】AC自动机(加强版)(AC自动机模板)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-24 00:23:38 185
原创 P3808 【模板】AC自动机(简单版)(AC自动机模板)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-24 00:02:45 191
原创 基于Keras的关于GAN的初学者demo
%tensorflow_version 1.xfrom keras.datasets import mnistfrom keras.layers import Dense,Dropout,Inputfrom keras.models import Model,Sequentialfrom keras.layers.advanced_activations import LeakyReLU...
2020-04-23 19:19:29 531 3
原创 CodeForces 270D Greenhouse Effect (DP+LIS)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-23 16:39:55 195
原创 CodeForces 320D Psychos in a Line (单调栈+DP)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-21 10:40:29 160
原创 CodeForces 214E Relay Race (DP+思维)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-19 19:35:26 290 1
原创 CodeForces 214D Numbers (DP+组合数学+前导零的细节)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-19 19:33:37 197
原创 学习一个简单的纯numpy实现的神经网络象限分类
import numpy as np#神经网络的分类任务#理论上两层神经网络就足够拟合任意函数#为了使得神经网络不仅仅只能拟合线性函数,引入了激活层#常见的激活函数有三种:阶跃,Sigmoid,ReLU函数def affine_forward(x,w,b): out=None N=x.shape[0] x_row=x.reshape(N,-1) out=np.dot...
2020-04-18 00:23:57 617
原创 HDU 5614 Baby Ming and Matrix tree (树链剖分+线段树区间修改)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-17 10:43:37 149
原创 Codeforces Round #635 (Div. 2) A,B,C,D
A#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson ...
2020-04-16 16:09:10 142
原创 Educational Codeforces Round 85 (Rated for Div. 2)(A,B,C)
A#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson ...
2020-04-16 16:06:46 159
原创 CodeForces 284E Coin Troubles (DP+判环+背包)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-12 20:52:16 195
原创 CodeForces 155C Hometask (DP+复杂做法)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-12 16:31:36 196
原创 CodeForces 1260F Colored Tree (树剖+计数思维+一点点DP思维)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-10 11:35:25 174
原创 CodeForces 239E World Eater Brothers (DP)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-09 23:26:09 154
原创 CodeForces 373E Watching Fireworks is Fun (DP+单调队列优化)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-05 21:26:05 178
原创 HDU 4866 Shooting (主席树+离散化优化+初始化问题)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-04-04 21:17:18 148
原创 在使用tensorflow和keras玩转机器学习时候遇到的错误
cannot import name 'dump_age' 2020.4.1我解决的方法:可能有多个werkzeug的存在,我在命令行里面卸载了werkzeug就没有这个错误了
2020-04-01 16:43:16 144
原创 HDU 4912 Paths on the tree (树链剖分+线段树+DP)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-03-31 19:54:28 197
原创 CodeForces 1062E Company (主席树第k大+dfs序性质)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-03-30 21:53:22 243
原创 CodeForces 373D Counting Rectangles is Fun (四维DP)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-03-27 16:29:07 168
原创 CodeForces 853C Boredom (主席树+分类讨论)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-03-27 10:36:50 240
原创 HDU 5029 Relief grain (树链剖分+权值线段树思想)
#include<bits/stdc++.h>using namespace std;#define debug cout<<"YES\n";#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define ...
2020-03-26 18:10:52 192
原创 HDU 5296 Annoying problem (树剖求LCA+链的距离)
#include<bits/stdc++.h>using namespace std;#define debug cout<<"YES\n";#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define ...
2020-03-23 19:32:29 123
原创 HDU 5293 Tree chain problem (树链剖分+LCA+树形DP)
#include<bits/stdc++.h>using namespace std;#pragma comment(linker, "/STACK:1024000000,1024000000") #define debug cout<<"YES\n";#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#de...
2020-03-21 11:34:28 166
原创 CodeForces 208E Blood Cousins (启发式合并+倍增)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-03-20 00:12:15 178
原创 CodeForces 246E Blood Cousins Return (树上启发式合并)
#include<bits/stdc++.h>using namespace std;#define debug puts("YES");#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define lson l,m...
2020-03-18 08:36:07 210
原创 HDU 5452 Minimum Cut (树链剖分)
#include<bits/stdc++.h>using namespace std;#define debug cout<<"YES\n";#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define ...
2020-03-17 15:17:23 133 1
原创 ZOJ 4053 Couleur (启发式合并+主席树)
#include<bits/stdc++.h>using namespace std;#define debug cout<<"YES\n";#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define ...
2020-03-10 17:31:59 225
原创 P4211 [LNOI2014]LCA (树链剖分+思维)
#include<bits/stdc++.h>using namespace std;#define debug cout<<"YES\n";#define rep(x,y,z) for(int (x)=(y);(x)<(z);(x)++)#define ll long long#define lrt int l,int r,int rt#define ...
2020-03-09 00:38:46 137
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人