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
1698
hdu
1698
Just a Hook(线段树之 成段更新)
JustaHook TimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorriblethin
LYHVOYAGE
·
2014-08-09 10:00
线段树
HDU
1698
Just a Hook
pid=
1698
JustaHookTimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission
hellojyj
·
2014-08-08 14:00
线段树
HDU
hook
a
Just
1698
HDU
1698
_Just a Hook
JustaHookTimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):17125 AcceptedSubmission(s):8547ProblemDescription InthegameofDotA,Pudge’smeathookisactuallyth
u011676797
·
2014-08-08 10:00
HDU
1698
——Just a Hook(线段树,区间修改)
JustaHookTimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):17013 AcceptedSubmission(s):8479ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythe
u014141559
·
2014-08-05 19:00
HDU -
1698
Just a Hook (线段树区间修改)
DescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorriblethingformostoftheheroes.Thehookismadeupofseveralconsecutivemetallicstickswhichareofthesamelength.NowPudgewantstodosomeoperationsonthe
u011345136
·
2014-08-03 09:00
hdu
1698
--Just a Hook(线段树修改区间值,求区间和)
JustaHookTimeLimit:4000/2000MS(Java/Others)MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):16817AcceptedSubmission(s):8360ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorr
u013015642
·
2014-07-30 21:00
HDU
1698
Just a Hook (线段树延迟标记(lazy))
题意:有n个数初始值都为1,m个操作a,b,c,表示把区间[a,b]变为c,求最后n个数的和。经典区间更新求和问题,需要用到延迟标记(或者说是懒惰标记),简单老说就是每次更新的时候不要更新到底,用延迟标记使得更新延迟到下次需要更新或询问的时候。#include #include #include #include #include #include #include #include #inclu
u012861385
·
2014-07-30 10:00
poj
1698
二部图多重最大匹配(拍电影)
题意:某演员想拍n部电影,每部电影有拍摄完毕的截止时间,以周为单位,而且每周只有给定的时间可以拍。另外每部电影有需要拍摄的天数。问此人能不能不耽误所有电影。思路:二部图多重最大匹配。将电影作为X部,每天作为Y部(Y部最多有50*7=350个点),若电影i可以在第j天拍摄就置c[i][j]为1。每个X部点的约束值为该电影总共要拍摄的天数(即源点与X部点的权值),每个Y部点的约束值为1,求此二部图的多
dumeichen
·
2014-07-27 18:00
HDU
1698
Just a Hook 【线段树】+【成段更新】+【lazy标记】
JustaHookTimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):15889 AcceptedSubmission(s):7897ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythe
u012846486
·
2014-07-08 20:00
hdu1698
poj
1698
Alice's Chance 拆点最大流
将星期拆点,符合条件的连边,最后统计汇点流量是否满就行了,注意结点编号。#include #include #include #include #include #include #include #include #include #include #defineeps1e-12 #defineINF0x7fffffff #definemaxn1000 usingnamespacestd; in
t1019256391
·
2014-06-26 19:00
华为荣耀3X Pro怎么样?华为荣耀3X Pro详细评测图文介绍
不仅如此,华为荣耀系列也要跟小米旗舰机型米3叫板,于是推出了联发科真八核机型荣耀3X,这款手机售价为
1698
元,尽管真八核MT6592跟小米3的骁龙800性能上还有所差异,但荣耀3X售价要比小米3便宜不少
佚名
·
2014-06-26 09:26
hdu
1698
Just a Hook (线段树功能:成段替换,总区间求和)
pid=
1698
ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorriblethingformostoftheheroes.Thehookismad
u012860063
·
2014-06-22 11:00
算法
线段树
HDU
【线段树】HDOJ
1698
Just a Hook
第一次写成段更新的线段树。。。刚开始不晓得记录节点信息好,也不知道什么时候lazy标记向下传递。。。现在终于理解了lazy标记。。。贴上自己写的代码。。不过一直不知道为嘛自己写的代码跑的没别人快。。。。#include #include #include #include #include #include #include #include #include #include #include
blankcqk
·
2014-06-19 10:00
HDU
1698
Just a Hook 线段树 成段替换
JustaHookTimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):15645 AcceptedSubmission(s):7750ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythe
u013368721
·
2014-06-16 13:00
线段树
HDU
poj2049--Finding Nemo
FindingNemoTimeLimit: 2000MS MemoryLimit: 30000KTotalSubmissions: 7317 Accepted:
1698
DescriptionNemoisanaughtyboy.Onedayhewentintothedeepseaallbyhimself.Unfortunately
u013015642
·
2014-05-22 11:00
POJ
1698
【题意】给你一个时限,一个工作的时间长度,和可以工作的日子(星期日到星期六),让你求出是否可以拍完所有的电影。【题解】建图是关键,我们可以列出两列,第一列是不同的电影,第二列是星期的日子,然后开始连边。当然,这时我们发现会有一些不和谐,也就是说,因为每部电影的时限不同,所以有一部分(星期)只能拍某部电影,而其他的不行。所以,我想到了,将其分开,也就是个管个的——时限久的可以连上时限短的(星期),最
cymxyym
·
2014-05-13 19:53
网络流
HDU
1698
Just a Hook(线段树:区间set,区间查询)
HDU
1698
JustaHook(线段树:区间set,区间查询)http://acm.hdu.edu.cn/showproblem.php?
u013480600
·
2014-03-26 19:00
ACM
HDU:
1698
Just a Hook
线段树区间更新,区间求和。模版题。#include #include #include #include #include #include #include #include #include #include #definelllonglong #defineINF2139062143 #defineinf-2139062144 #defineMOD20071027 #defineMAXN20
kkkwjx
·
2014-03-15 21:00
线段树
HDU
1698
Just a Hook (线段树)
pid=
1698
/*843ms,2288KB*/ #include #include usingnamespacestd; #definelsonl,m,rt>1))*cache[rt]; sum[rt
synapse7
·
2014-02-19 11:00
C++
线段树
ACM
HDU
hdu
1698
(区间延迟更新+区间求和)
1013msG++代码 #include #include #include #include #include #include usingnamespacestd; constintNUM=100010; typedefstructnode { intleft,mid,right,key; }node; nodeT[NUM>1; flag[u]=0; if(l==r) { T[u].key=1
qeroLai
·
2014-02-13 17:18
include
hdu
1698
(区间延迟更新+区间求和)
1013msG++代码#include#include#include#include#include#includeusingnamespacestd;constintNUM=100010;typedefstructnode{intleft,mid,right,key;}node;nodeT[NUM>1;flag[u]=0;if(l==r){T[u].key=1;return;}intmid=(
qeroLai
·
2014-02-13 17:18
include
ACM之路--线段树
hdu
1698
Just a Hook(线段树 成段更新+总区间求和)
pid=
1698
题意:给定一根棒的长度,它上面有价值1,2,3种,初始价值为1,每次输入的x,y,z表示把区间[x,y]的价值全部变为z;问最后这根棒的总价值是多少。
u013081425
·
2014-02-11 10:00
线段树
成段更新
上海最大网上家园——邀您免费入驻上海滩网“宝贝大卖场”
上海最大网上家园——邀您免费入驻上海滩网“宝贝大卖场”免费入住可获得上海滩网首页中部按钮广告图片位宣传10天详情咨询:付先生电话:139-
1698
-6665QQ:1667090640入住报名:http
小样的别跑
·
2014-01-04 16:00
HDU
1698
Just a Hook(成段更新)
pid=
1698
线段树功能: update:成端替换跟着NotOnlySuccess大牛学线段树#include #definelsonl,m,rt>1))*col[rt]; sum
fjy4328286
·
2013-12-07 20:00
HDU-
1698
Just a Hook
JustaHookTimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):13918 AcceptedSubmission(s):6886ProblemDescriptionInthegameofDo
·
2013-11-15 20:00
HDU
HDU
1698
线段树成段更新
水。 #include#include#include#includeusingnamespacestd;constintmaxn=100000;structtree{ intl; intr; intsum;//用来标记当前是否被染成混合色;0表示是混合色,1不是;}T[maxn0) { T[u>1; build(l,mid,u>1; //父区域为杂色是进行下面
u012350533
·
2013-11-04 11:00
HDU
1698
:Just a Hook(线段树区间更新)
ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorriblethingformostoftheheroes.Thehookismadeupofseveralconsecutivemetallicstickswhichareofthesamelength.NowPudgewantstodosomeoperatio
libin56842
·
2013-10-29 17:00
线段树
HDU
C#修改IP地址
分类: C#语言 2010-09-1214:16
1698
人阅读 评论(1) 收藏 举报 c
oMingZi12345678
·
2013-09-13 21:00
c#语言
poj
1698
Alice's Chance 最大流
Alice'sChanceTimeLimit:1000MS MemoryLimit:10000KTotalSubmissions:4472 Accepted:1884DescriptionAlice,acharminggirl,havebeendreamingofbeingamoviestarforlong.Herchanceswillcomenow,forseveralfilmmakingcom
u010422038
·
2013-09-07 15:00
HDU
1698
Just a Hook
转载请注明出处:http://blog.csdn.net/a1dark分析:说到这题、满脸都是泪。。、本应该轻松1A的、结果由于我的初始化mark的时候、没注意到就把mark放到if(l==r)条件判断里面了、这样就只能初始化到最低层的节点、无语了啊、找了好久的错误、泪流满面。。其实这题还有一个做法、因为是不断覆盖、可以逆序模拟这个过程、是可以暴力过的#include #defineN100225
verticallimit
·
2013-08-28 22:00
线段树
ACM
成段更新
poj 2528 离散化+线段树 hdu
1698
线段树 线段树题目类型一:染色计数 外加离散化
第一次听到离散化是今年省赛的时候,一道矩形并的题,很水,就两个矩形...今天再去做线段树已经发现离散化忘得差不多了...水逼的悲哀啊...先看简单点的hdu
1698
http://acm.hdu.edu.cn
u011026968
·
2013-08-25 20:00
hdu
1698
线段树 just a “trick” *_*
ViewCode//第一次做线段树,不怎么会,试着模仿别人的写法,修修改改//继续努力!!!//初始状态全为1,x,y,z代表把x->y区间改为z#include#includeconstintMAX=100010;#defineL(x)x>1struct{intcolor,l,r;}node[3*MAX];voidtreeinit(){memset(node,0,sizeof(node));}v
haha593572013
·
2013-08-19 18:00
URAL
1698
题目大意:统计位数不大于n的自守数的个数。 Time Limit:2000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64u 数据规模:1<=n<=2000。 理论基础:
·
2013-08-12 19:00
r
POJ
1698
Alice's chance 网络流最大流的题目,但是主要是考建图,图建出来后就套模板就行
说一下题意:有一个小女孩从小就梦想成为一名影星,现在机会来了,有很多电影公司找她拍电影,但是这些拍电影的日程安排之间可能还有冲突,但是女孩不想错过任何机会,想把每个公司的电影都接下来,但是她不知道能不能接下所有的电影,所以找到了你优秀的ACMER来帮忙解决问题。数据的输入如下:有T组数据每组先有一个N表示要找她拍的电影的个数,其中N #include #include #include #incl
u011401504
·
2013-08-12 14:00
poj
poj
网络流
最大流
cha
1698
建图
Alices
hdu
1698
线段树
//注意要成段更新,更新到段,不能到点 //=========================================== //segmenttree //finalversion //bykevin_samuel(fenice) #include #include #include usingnamespacestd; #defineMAXN100000 #defineINF0x3
Kevin_Samuel
·
2013-08-09 23:00
HDU
1698
Just a Hook(线段树)
题意:初始时整个区段值为1,然后每次使区段[L,R]内的值全部改为某个值,最后输出整个区段和思路:线段树区间维护,成段替换。模板题,具体方法见代码,或者参看刘汝佳训练指南。#include #include #include #defineM((R+L)>>1) #definels(o=0)sumv[o]+=setv[ls]*(M-L+1);elsesumv[o]+=sumv[ls]; if(se
blzorro
·
2013-08-04 22:00
线段树
区间更新
成段替换
HDU 题目
1698
Just a Hook(线段树)
JustaHookTimeLimit:4000/2000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):12674 AcceptedSubmission(s):6309ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythe
u011282069
·
2013-08-04 12:00
hdoj
1698
--Just a Hook 线段树练习
/*********************************************** Copyright:Glder Author:Glder Date:2013-08-0314:54:46 Destription: 1、插线问题(成段更新) 2、建树结构体中是需要多加个元素权值 3、建树操作中注意 A: if(l==r) { s[root].num=1; s[root].x=0; c
lgdblue
·
2013-08-03 15:00
C++
线段树
hdu
1698
Just a Hook 线段树成段修改
#include #include #definemaxn100000 structnode{ intl,r,w,to;//to记录该段的修改情况,0为未修改 }e[maxn*4]; intd[50005]; voidbuild(inta,intb,intc) { if(a==b) { e[c].l=e[c].r=a; e[c].w=1; e[c].to=0; return; } e[c].l=a
a601025382s
·
2013-07-19 19:00
线段树
成段修改
hdu
1698
Just a Hook(线段树基础)
成段更新的线段树,加入了延时标记............线段树这种东西细节上的理解因人而异,还是要自己深入理解......慢慢来 #include #include #include #include #include #include #include #include #include #include #include #include//形如INT_MAX一类的 #
·
2013-07-19 18:00
HDU
hdu
1698
Just a Hook(线段树基础)
成段更新的线段树,加入了延时标记............线段树这种东西细节上的理解因人而异,还是要自己深入理解......慢慢来#include #include #include #include #include #include #include #include #include #include #include #include//形如INT_MAX一类的 #defineMAX1000
paradiserparadiser
·
2013-07-19 00:00
线段树题目集
//hdu1754求区间最大值//hdu1166求区间和//hdu
1698
成段更新//poj3468成段更新//ural1019覆盖加统计最长同一个颜色//zoj2301和上一题差不多,但是这个染色染的是点
u010138811
·
2013-07-16 09:00
线段树
hdu
1698
线段树成段更新
这么重要的数据结构还是得学啊。仿notonlysuccess的代码风格#include #include #include usingnamespacestd; #definelsonl,m,rt>1))*col[rt]; sum[rt>1)*col[rt]; col[rt]=0; } } voidbuild(intl,intr,intrt){ col[rt]=0; sum[rt]=1; if(
t1019256391
·
2013-07-14 17:00
线段树 [成段更新] HDU
1698
Just a Hook
成段更新,需要用到延迟标记(或者说懒惰标记),简单来说就是每次更新的时候不要更新到底,用延迟标记使得更新延迟到下次需要更新or询问到的时候.此处建议在纸上模拟一遍。ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorriblethingformostoftheheroes.Thehookismadeupofsev
gaotong2055
·
2013-07-11 14:00
线段树 [成段更新] HDU
1698
Just a Hook
成段更新,需要用到延迟标记(或者说懒惰标记),简单来说就是每次更新的时候不要更新到底,用延迟标记使得更新延迟到下次需要更新or询问到的时候.此处建议在纸上模拟一遍。ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorriblethingformostoftheheroes.Thehookismadeupofsev
从此醉
·
2013-07-11 14:00
HDU
线段树 [成段更新] HDU
1698
Just a Hook
成段更新,需要用到延迟标记(或者说懒惰标记),简单来说就是每次更新的时候不要更新到底,用延迟标记使得更新延迟到下次需要更新or询问到的时候.此处建议在纸上模拟一遍。ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorriblethingformostoftheheroes.Thehookismadeupofsev
gaotong2055
·
2013-07-11 14:00
POJ
1698
Alice's Chance 【网络流-构图】
网络流构图题目,构图方式:每部电影与源之间连边,权值为本电影拍摄需要的天数。将所有的天数都抽象成点(最多为50*7),将每部电影与可行的日子之间连接一条边,权值为1,然后将所有的日子与汇点连接一条边,权值为1.在这个图上面跑最大流,流经每个电影的最大流量为规定的天数,而且,如果从某个电影出发的流流经了某天的话,将不会有其它流流经——因为每一天与汇点之间的权值为1,即最多有一个电影的流可以通过该天流
yang_7_46
·
2013-06-26 13:00
Problem A hdu
1698
Just a Hook
JustaHookTimeLimit:4000/2000MS(Java/Others)MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):11857AcceptedSubmission(s):5890ProblemDescriptionInthegameofDotA,Pudge’smeathookisactuallythemosthorr
u010228612
·
2013-06-18 14:00
网络流题单
最大流 POJ1273DrainageDitches POJ1274ThePerfectStall(二分图匹配) POJ
1698
Alice'sChance POJ1459PowerNetwork POJ2112OptimalMilking
yang_7_46
·
2013-06-16 15:00
hdu
1698
Just a Hook(线段树区区)
pid=
1698
题目大意: 给出初试值都为1的区间[1,n] 有M次操作,每次操作表示将[a,b]的值全部替换成c 最后输出总值的大小解题思路
qq7366020
·
2013-06-15 19:00
线段树
HDU
上一页
8
9
10
11
12
13
14
15
下一页
按字母分类:
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
其他