E-COM-NET
首页
在线工具
Layui镜像站
SUI文档
联系我们
推荐频道
Java
PHP
C++
C
C#
Python
Ruby
go语言
Scala
Servlet
Vue
MySQL
NoSQL
Redis
CSS
Oracle
SQL Server
DB2
HBase
Http
HTML5
Spring
Ajax
Jquery
JavaScript
Json
XML
NodeJs
mybatis
Hibernate
算法
设计模式
shell
数据结构
大数据
JS
消息中间件
正则表达式
Tomcat
SQL
Nginx
Shiro
Maven
Linux
TOT
蛇形填数n*n
(n#include#defineMAX100inta[MAX][MAX];intmain(){inti,j,n,
tot
=0;scanf("%d",&n);memset(a,0
隐者_
·
2020-07-05 04:19
#
常用算法
多线程
大量运算放到主线程//不要把修改页面的代码放在子线程,不会得到及时更新//开辟一个子线程用来处理某些事[NSThreaddetachNewThreadSelector:@selector(NewThread)
toT
于海明
·
2020-07-05 04:10
iOS
开发资料
1015 德才论(25 分)
#include#include#include#includeusingnamespacestd;constintmaxn=1e5+10;structstu{intid,dscore,cscore,
tot
DaiMorph
·
2020-07-05 02:24
BZOJ 3930 CQOI2015 选数 莫比乌斯反演
include#defineM10001000#defineINF0x3f3f3f3f#defineMOD1000000007usingnamespacestd;intmu[M],prime[1001001],
tot
PoPoQQQ
·
2020-07-05 02:21
莫比乌斯反演
BZOJ
NOIP普及组2014--珠心算测验
珠心算测验第一题其实非常简单,如果不去重,就会导致只有三十分代码如下:#includeusingnamespacestd;longlongh[1000000];longlongshu[200];intidx,n,
tot
面面无敌帅
·
2020-07-05 01:29
普及组
Croc Champ 2013 - Round 1 题解
只需要记录连得边数的点的个数即可轻易判断C:个人觉得是一个比较蛋疼的题,开始还看错了,以为不允许出现0,>_#include#include#includeusingnamespacestd;constintN=15;intn,
tot
mlzmlz95
·
2020-07-05 00:15
codeforces题解
bzoj 4519: [Cqoi2016]不同的最小割 分治&最小割
AC代码如下:#include#include#include#include#defineN1005#defineM20005usingnamespacestd;intn,m,
tot
=1,sta,gol
lych_cys
·
2020-07-04 23:56
bzoj
bzoj 2547: [Ctsc2002]玩具兵 bfs&最大匹配
include#defineN115#defineM1005usingnamespacestd;constintdx[4]={-1,1,0,0},dy[4]={0,0,-1,1};intm,n,cnt,pt,
tot
lych_cys
·
2020-07-04 23:56
bzoj
我在CentOS下学习oracle的笔记
---------->查看系统进程、登陆用户等信息[root@myLinux~]#top-22:07:55up1:09,1user,loadaverage:0.40,0.22,0.08Tasks:48
tot
liangyicool
·
2020-07-04 21:46
J2EE
poj2002 数正方形 hash
直接上渣代码了#includeusingnamespacestd;structgtype{intx,y,next;}g[3000];intfirst[1000100],
tot
,n,x[3010],y[3010
琴空
·
2020-07-04 21:36
POJ
ccf csp 201912-1
newScanner(System.in);intn=sc.nextInt();int[]people=newint[]{0,0,0,0};intnow=1;inttot=0;intwho=0;while(
tot
大吉大利,今晚AC
·
2020-07-04 20:51
bzoj 4026 dC Loves Number Theory (主席树+数论+欧拉函数)
definelllonglong#defineilinline#defineN50010#definemaxn1000000#definemod1000777usingnamespacestd;intn,q,ctp,
tot
guapisolo
·
2020-07-04 16:34
bzoj
主席树
数论
欧拉函数
SP1741 TETRIS3D - Tetris 3D
(a):(b))usingnamespacestd;intn,m,k,x,y,z,sx,sy,sz,f[16000039],ans,
tot
,pus;shortflag[16000039];inlinevoidpush
fxt275307894a
·
2020-07-04 16:12
spoj
luogu P2982 [USACO10FEB]Slowing down G
代码实现:#include#includeusingnamespacestd;intn,m,k,x,y,ans,
tot
,pus,dfn[200039],l[100039],r[100039],dh,f[
fxt275307894a
·
2020-07-04 16:12
洛谷
dfs
欧拉序
树状数组
luogu P6476 [NOI Online 2 提高组]涂色游戏color
(a):(b))usingnamespacestd;longlongt,n,m,k,x,y,z,ans,
tot
,pus,now;inlinevoidread(longlong&x){chars=getchar
fxt275307894a
·
2020-07-04 16:11
洛谷
luogu P6565 [NOI Online #3 入门组]最急救助
(a):(b))usingnamespacestd;intn,m,k,ans,
tot
,pus,num[139],h[139];chars[139][139],a[539];intmain(){//freopen
fxt275307894a
·
2020-07-04 16:11
洛谷
洛谷 P3385 【【模板】负环】
代码:#includeusingnamespacestd;structnode{intl,r,w;};nodee[6010];intn,m,
tot
;intdis[2010];voidadd(intx,inty
那一条变阻器
·
2020-07-04 11:00
ClickHouse 零散小知识总结(二)
1.重命名renametablet1
tot
22.SQLrow()number问题因为clickhouse不支持开窗函数,特此写一个复杂sql代替该函数的功能selectuid,value,row_numberfrom
aaa8210
·
2020-07-04 10:08
clickhouse
UVa11300 - Spreading the Wealth
#includeusingnamespacestd;typedeflonglongll;constintmaxn=1000000+10;llA[maxn],C[maxn],
tot
,M;intmain()
BEconfidence
·
2020-07-04 10:09
UVA
[树形DP][状压DP] SRM599 950-point SimilarNames
只需要所有有限制的
tot
个字符串,答案乘上(n−
tot
)!即可。考虑在树上状压DP。fu,S表示以u为根的子树中用去有限制的标号集合为S的方案数。
Vectorxj
·
2020-07-04 09:46
动态规划
【洛谷P4879】ycz的妹子
这样的话,直接选择线段树,考虑加
tot
就可以了。注释在代码里#
Chiyo小朋友
·
2020-07-04 08:53
线段树
NKOJ 4038(CQOI 2017) 小Q的棋盘(贪心)
=N,那么答案就是N+1如果L#include#include#include#defineN12345usingnamespacestd;intv,n,l;intLA[N],NE[N],EN[N],
TOT
Mogician_Evian
·
2020-07-04 07:03
贪心
hdu4609 傅里叶变换
1>=1;LLans,
tot
;ans=
tot
=(LL)n*(n-1)*(n-2)/6;an
丿Smile灬晨星
·
2020-07-04 06:39
数学
洛谷P1141 01迷宫 经典 Dfs + 记忆化搜索,并查集
include#include#include#include#include#includeusingnamespacestd;constintN=1005;charmap[N][N];intn,m,
tot
Jason_ZED
·
2020-07-04 06:12
搜索
bzoj2301 [HAOI2011]Problem b(求gcd==k的个数)(莫比乌斯反演+容斥原理)
n/k⌋∑y=1⌊m/k⌋∑d|gcd(x,y)μ(d)令n#include#definelllonglong#defineN50000+5intT,a,b,c,d,k,mu[N],prime[N],
tot
Icefox_zhx
·
2020-07-04 06:36
bzoj
莫比乌斯反演
容斥原理
分块
「学习笔记」Eratosthenes筛法
筛法是求1~n中的素数的筛法从2开始,把其倍数(从2倍开始)剔除,剩下的即素数#includeusingnamespacestd;boolp[100001];//p[i]=true表示i是素数intn,
tot
_Gion
·
2020-07-04 04:02
C - Critical Links UVA - 桥TARJAN割边
include#include#include#includeusingnamespacestd;structnode{intfrom,to,next,flag;}e[1500000];intcont,
tot
ID_BePosit
·
2020-07-04 04:17
图论
cqoi2016
include#include#include#include#defineinf1050000000#defineN855#defineM17005usingnamespacestd;intn,m,S,T,
tot
wcy_1122
·
2020-07-04 02:04
题解
套题总结
P3172 [CQOI2015]选数 [莫比乌斯反演+杜教筛]
include#defineN5000050#defineMod1000000007#defineLLlonglongusingnamespacestd;intn,k,L,R;intprim[N],isp[N],
tot
FSYo
·
2020-07-04 02:21
莫比乌斯反演
杜教筛
洛谷选数
#include#includeintn,k,
tot
=0,sum=0;inta[10000];boolis_prime(longlongn){for(longlongi=2;ik){if(is_prime
MMZKXL
·
2020-07-04 01:05
起底四川信托百亿资金暴雷:接盘烂尾楼、输血问题机构大股东
四川信托的理财经理们查询发现,
TOT
大量底层资产为垃圾资产,并有巨额资金流向此前暴雷的安信信托大股东。
财经杂志
·
2020-07-04 00:00
【NOIP模拟赛19.8.26】死宅与陷阱
只有5分qwq正解直接暴力dfs算概率,最后把概率排序增加陷阱代码#includeusingnamespacestd;#defineN100005#definedbdoubleintn,m,p,s,t,
tot
best_hacker
·
2020-07-02 14:13
题解
模拟赛
模拟赛
设置label的行间距
NSMutableParagraphStylealloc]init];paragraphStyle.lineSpacing=10;//字体的行间距intnotDown=0;for(NSString*ssin_
Tot
心底碎片
·
2020-07-02 03:46
《利用python进行数据分析》常见问题汇总(二)
利用python进行数据分析麦金尼代码实测常见问题汇总第6章数据加载、存储与文件格式逐块读取文本文件调用Series的order属性出错
tot
=
tot
.order(ascending=False)具体报错
zhh_2017
·
2020-07-02 03:00
数据分析
图书代码修正
字典树整理加几个例题
接下来沾上我的板子//找前缀#include#include#includeusingnamespacestd;constintmaxn=2000010;intn,m,rt,trie[maxn][27],
tot
fighting_yifeng
·
2020-07-02 00:00
字符串
GCD(莫比乌斯反演)
莫比乌斯反演入门题目:题解#include#include#include#include#includeusingnamespacestd;constintmaxn=100005;intT,a,b,c,d,e,
tot
Q王路飞
·
2020-07-01 18:05
数论
Python练习题答案: 字符串后缀【难度:2级】--景越Python编程实例训练营,1000道上机题等你来挑战
字符串后缀【难度:2级】:答案1:defstring_suffix(str_):
tot
=0foriinxrange(len(str_)):fora,binzip(str_,str_[i:]):ifa!
景越
·
2020-07-01 17:33
Python编程初级练习题
排序
排序题目争议讲真,我认为题面是有一点问题的:题目中有这样一些语句“若根据前x个关系即发现存在矛盾(如Ausingnamespacestd;queueq;chara,b,op;vectorans;intn,m,
tot
Eleven谦
·
2020-07-01 17:00
【NOIP】选择客栈
200000;inttot[maxn],sum[maxn],h[maxn];intn,k,p;//分别表示客栈的个数,色调的数目和能接受的最低消费的最高值intans,now;intmain(){memset(
tot
AliceBuJu
·
2020-07-01 16:53
贪心
模拟
7-7 整数分解为若干项之和 (20 分)
输入格式:每个输入包含一个测试用例,即正整数N(0inta[32];intn,num;voiddfs(intcur,inttot){inti;if(cur>n)return;//剪枝1if(
tot
>n)
Skyed.blue
·
2020-07-01 13:47
算法
pta-作业
c++实验1 7-4 求整数的位数及各位数字之和
输入样例:321输出样例:36代码如下:#includeusingnamespacestd;intmain(){intn,num=0,
tot
=0;cin>>n;while(n)//此方法拆
Skyed.blue
·
2020-07-01 13:46
pta-作业
51nod 1135 原根 就是原根...
include#include#include#include#include#defineN100000#defineLLlonglongusingnamespacestd;LLprime[100010],
tot
Ren_Ivan
·
2020-07-01 12:45
数学
原根
【noip 2011】选择客栈
很巧妙的方法O(n)就可以做边读入边处理记录:①now:为离当前客栈最近的,花费不超过p的客栈的坐标②sum[x]:已经对答案有过贡献的(与它之后的客栈之间有最小花费不超过p的)颜色为x的客栈的数量③
tot
Loi_LXTT
·
2020-07-01 11:52
===基础算法===
模拟
===脑洞&&思维题===
===noip系列===
bzoj2820 [bzoj2820]YY的GCD(线性素数筛+莫比乌斯反演)
首先我们可以像bzoj2301一样把后一部分化简,得到(假定nusingnamespacestd;#definelllonglong#defineN10000010intT,n,m,mu[N],prime[N],
tot
Icefox_zhx
·
2020-07-01 10:52
bzoj
莫比乌斯反演
BZOJ3732 LCA
includeusingnamespacestd;constintN=1e5+10;inthead[N],Next[N],ver[N],edge[N],mf[N][20],f[N][20],d[N],fa[N],
tot
Gipsyu
·
2020-07-01 09:24
数据结构
图论
次短路(非严格)
programpro;vari,j,n,m,num,
tot
:longint;min,cmin:real;flag:boolean;point:array[0..205]ofrecordx,y
Byte97
·
2020-07-01 09:12
图论
牛客练习赛61 C.四个选项(01背包+哈希压状态)
其次有m(0usingnamespacestd;constintN=4;intm,x,y;intdp[N*N*N*N],a[13],
tot
,cnt,now[4],b[4],nex,pre;boolvis
Code92007
·
2020-07-01 08:06
#
背包九讲
动态树分治——模板整理
includeusingnamespacestd;constintmaxn=100005,maxe=200005;intn,m,w[maxn],last_print;intfir[maxn],nxt[maxe],son[maxe],
tot
Lynstery
·
2020-07-01 08:58
树分治
我的OI学习足迹
ABC 171E Red Scarf (位运算)
⊕⋯⊕bi−1⊕⋯bna_i=b_1\oplus\cdots\oplusb_{i-1}\oplus\cdotsb_nai=b1⊕⋯⊕bi−1⊕⋯bn,要求还原出bbb序列前置芝士异或基础知识解题思路设
tot
_Wolverine
·
2020-07-01 08:21
题解
AtCoder
Codeforces Round #111 (Div. 2) E. Buses and People 线段树
应该也可但是写起来比较麻烦我们就写线段树首先我们把人和车都按上车起始点排序这样可以减少一维剩下还有终止点和时间这两维我们对时间离散化并且以时间(车辆的信息)开一棵线段树维护终止点的最大值以及车辆的编号(应该是不存在时间相同的车的)对于每辆车我们更新对应时间点的终止点以及车辆编号对于每个人我们根据维护的终止点最大值在pos~
tot
xtuls
·
2020-07-01 06:03
线段树
codeforces
上一页
14
15
16
17
18
19
20
21
下一页
按字母分类:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
其他