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
Kingdom
【codeforces 115E】Linear
Kingdom
Races (datestructs(seg.tree)+dp)
E.LinearKingdomRacestimelimitpertest5secondsmemorylimitpertest256megabytesinputstandardinputoutputstandardoutputYouareacarraceorganizerandwouldliketoarrangesomeracesinLinearKingdom.LinearKingdomhasnco
ALPS233
·
2015-12-08 20:00
dp
codeforces
segment-tr
HDU5583
Kingdom
of Black and White
KingdomofBlackandWhiteTimeLimit:2000/1000MS(Java/Others) MemoryLimit:65536/65536K(Java/Others)TotalSubmission(s):65 AcceptedSubmission(s):33ProblemDescriptionIntheKingdomofBlackandWhite(KBW),the
u013068502
·
2015-11-29 11:00
HDU
HDU 5583
Kingdom
of Black and White(依旧是暴力)——2015ACM/ICPC亚洲区上海站
KingdomofBlackandWhiteTimeLimit:2000/1000MS(Java/Others) MemoryLimit:65536/65536K(Java/Others)TotalSubmission(s):0 AcceptedSubmission(s):0ProblemDescriptionIntheKingdomofBlackandWhite(KBW),therear
queuelovestack
·
2015-11-28 18:00
ACM
暴力
SZU:A12 Jumping up and down
Case Time Limit: 10000MS Time Limit: 10000MS Judger: Number Only Judger Description In the
kingdom
·
2015-11-13 20:15
ping
微软对学生免费提供Visual Studio等开发软件(包括中国)
该项目称为Dreamspark计划,目前该计划覆盖以下国家: United States, the United
Kingdom
, Canada, China, Germany, France, Finland
·
2015-11-13 17:17
IO
Codeforce 143B - Help
Kingdom
of Far Far Away 2
Help
Kingdom
of Far Far Away 2 time limit per test 2 seconds memory limit per test 256 megabytes
·
2015-11-13 12:29
code
HDU 1025 Constructing Roads In JGShining's
Kingdom
http://acm.hdu.edu.cn/showproblem.php?pid=1025 题目有一定迷惑性,实际就是求LIS,我原来掌握的朴实的O(n^2)算法果断超时,新学了一种二分dp O(nlog(n))的算法,直接上模板了,还要多多体会啊 View Code #include <iostream> using namespace std ;
·
2015-11-13 02:20
struct
[HNOI2008
Kingdom
]
[关键字]:图论 弦图的色数 [题目大意]:就是最少的颜色染完所有点使得每条边相邻点都颜色不同,也就是图的色数。 //========================================================================== [分析]:首先它给出的图是一个弦图,所以有特殊的算法来求色数。首先用最大势算法求出完美消除序列,然后按照序列的逆序进行染色,每
·
2015-11-13 00:30
2008
POJ 3608 Bridge Across Islands(计算几何の旋转卡壳)
Description Thousands of thousands years ago there was a small
kingdom
located in the middle of the
·
2015-11-13 00:10
bridge
codeforces 115E Linear
Kingdom
Races 线段树 + DP 好题
参考了这里 http://blog.sina.com.cn/s/blog_6a6aa7830100x890.html 题意:有N条赛道,每一条初始时都是坏的,修复第i条赛道的费用是cost[i];赛道上会举办m个赛事,每个赛事会用到[L,R]之间的赛道,而且要保证赛事进行必须使得这一段的赛道完好,每项赛事还可以获得一定的钱数。问题要求安排哪些比赛可以使得收益最大。 可以设dp[i]表
·
2015-11-12 21:32
codeforces
HDU 5029 Relief grain(离线+线段树+启发式合并)(2014 ACM/ICPC Asia Regional Guangzhou Online)
pid=5029 Problem Description The soil is cracking up because of the drought and the rabbit
kingdom
·
2015-11-12 21:30
online
HDU 3681 Prison Break(BFS+二分+状态压缩DP)
Problem Description Rompire is a robot
kingdom
and a lot of robots live there peacefully.
·
2015-11-12 21:01
break
SQL server创建角色和用户
use[Three_
Kingdom
] exec sp_addrole'role1' 创建角色role1 grant update,selete
·
2015-11-12 16:25
SQL Server
Help
Kingdom
of Far Far Away 2
唉~~~格式处理题,水题啊。。。。。。 细节还是很重要的 View Code 1 #include<iostream> 2 #include<cstring> 3 using namespace std; 4 5 int main() 6 { 7 char data[110]; 8 char newdata[200]; 9 for
·
2015-11-12 16:49
codeforces
HDU 4004 The Frog's Games 【二分】
Problem Description The annual Games in frogs'
kingdom
started again.
·
2015-11-12 15:09
games
hdu 1025:Constructing Roads In JGShining's
Kingdom
(DP + 二分优化)
Constructing Roads In JGShining's
Kingdom
Time Limit: 2000/1000 MS (Java/Others)  
·
2015-11-12 15:11
struct
UVA1455 -
Kingdom
(并查集 + 线段树)
UVA1455 -
Kingdom
(并查集 + 线段树) 题目链接 题目大意:一个平面内,给你n个整数点,两种类型的操作:road x y 把city x 和city y连接起来,line fnum
·
2015-11-12 15:47
dom
HDU 1025 Constructing Roads In JGShining's
Kingdom
(DP+二分)
点我看题目 题意 :两条平行线上分别有两种城市的生存,一条线上是贫穷城市,他们每一座城市都刚好只缺乏一种物资,而另一条线上是富有城市,他们每一座城市刚好只富有一种物资,所以要从富有城市出口到贫穷城市,所以要修路,但是不能从富有的修到富有的也不能从贫穷的修到贫穷的,只能从富有的修到贫穷的,但是不允许修交叉路,所以问你最多能修多少条路。 题意 :这个题一开始我瞅了好久都没觉得是DP,后来二师兄给讲
·
2015-11-12 09:40
struct
hdu--(1025)Constructing Roads In JGShining's
Kingdom
(dp/LIS+二分)
Constructing Roads In JGShining's
Kingdom
Time Limit: 2000/1000 MS (Java/Others)  
·
2015-11-11 19:54
struct
uva-----11292 The Dragon of Loowater
Problem C: The Dragon of Loowater Once upon a time, in the
Kingdom
of Loowater, a minor nuisance turned
·
2015-11-11 19:08
water
hdu 1025 Constructing Roads In JGShining's
Kingdom
http://acm.hdu.edu.cn/showproblem.php?pid=1025 题意:题目的意思就是有两种城市,穷和富,要富的运到穷的里面问你最多能建几条路。 思路:就是按穷的递增序列来找富的城市里的最大上升子序列。就是LIS法,因为有500000个数据所以用普通的方法肯定超时,那么就用二分查找就可以了。每次就是找第一个比这个数大的数如果没有就放在最右边把最长的序列加一,否则把第
·
2015-11-11 17:51
struct
Constructing Roads In JGShining's
Kingdom
JGShining's
kingdom
consists of 2n(n is no more than 500,000) small cities which are located in two parallel
·
2015-11-11 17:17
struct
JDK1.5官方下载 _JDK1.5API(chm)下载 以及 JDK环境变量配置(另附tomcat环境变量设置)
JDK1.5官方下载 _JDK1.5API(chm)下载 以及 JDK环境变量配置(另附tomcat环境变量设置) 引自:http://hi.baidu.com/
kingdom
031/blog/item
·
2015-11-11 16:02
tomcat
hdu4777 Rabbit
Kingdom
TimeLimit:6000/3000MS(Java/Others) MemoryLimit:32768/32768K(Java/Others)TotalSubmission(s):1927 AcceptedSubmission(s):664ProblemDescriptionLonglongago,therewasanancientrabbitkingdomintheforest.E
Kirito_Acmer
·
2015-11-11 15:00
树状数组
hdu 4004 The Frog's Games
pid=4004 The annual Games in frogs'
kingdom
started again.
·
2015-11-11 14:51
games
《天国王朝》 观后记录..
《天国王朝》(
Kingdom
of Heaven), 也有其他译名 类似:王者天下, 还是叫做《天国王朝》比较有史诗的韵味,导演是: Ridley Scott, 他的著作还有(比较广为人知的
·
2015-11-11 13:08
记录
HDU 4777 Rabbit
Kingdom
--容斥原理+树状数组
题意: 给一个数的序列,询问一些区间,问区间内与区间其他所有的数都互质的数有多少个。 解法: 直接搞有点难, 所谓正难则反,我们求区间内与其他随便某个数不互质的数有多少个,然后区间长度减去它就是答案了。 那么怎么求区间内与区间其他某个数不互质的数的个数(记为cnt)呢? 我们用L[i],R[i]表示在整个序列中左边与 i 最近的与 i 不互质的数的位置,R[i]表示右边的,L[i],R[i]我
·
2015-11-11 11:38
树状数组
[UVA] 11292 - Dragon of Loowater
Problem C: The Dragon of Loowater Time limit: 1.000 seconds Once upon a time, in the
Kingdom
of Loowater
·
2015-11-11 05:12
water
hduoj1025——dp, lis
hduoj1025——dp, lis Constructing Roads In JGShining's
Kingdom
Time Limit: 2000/1000 MS (Java/Others)&
·
2015-11-11 00:48
HDU
HDU 4777 Rabbit
Kingdom
(树状数组)
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4777 题意:给出一个长度为n的数列,m个询问。每次询问区间[L,R]内有多少个数字与该区间内其他所有数字互质? 思路:计算每个数字向左向右能够延伸的最大区间[L,R]使得该区间内所有数字与该数字互质。并记录对于每个位置x,哪些数字的最左侧到达了x+1。然后输入所有询问,按照左区间升序。将每个区间依
·
2015-11-09 14:47
树状数组
codeforces 260E Dividing
Kingdom
(函数式线段树)
题目链接:http://codeforces.com/problemset/problem/260/E 题意:给出二维平面上一些点,画出四条线,两条平行于X轴两条平行于Y轴,将平面分为9块,使得每块中的点个数为给定的9个数。 思路:按照Y坐标建立线段树。枚举9个数的位置,判断可行性。 #include <iostream> #include <cstdio> #
·
2015-11-09 14:12
codeforces
HDU3466——背包DP——Proud Merchants
For such a long time, it was the most wealthy and powerful
kingdom
in the world.
·
2015-11-07 14:30
ant
Max's
kingdom
刚开始还打算用map,后来发现,按x第一关键字, y第二关键字排序即可, 感觉有点像基数排序 #include <iostream> #include <stdio.h> #include <algorithm> using namespace std; #define MAX 1000000 struct per {
·
2015-11-07 13:13
dom
HDU 1025 Constructing Roads In JGShining's
Kingdom
(DP)
Problem Description JGShining's
kingdom
consists of 2n(n is no more than 500,000) small cities which
·
2015-11-07 11:36
struct
Regionals 2013 :: North America - Southeast USA
North America - Southeast USA It Takes a Village As a Sociologist, you are studying a certain
kingdom
·
2015-11-07 10:35
out
CF286-D
limit per test 256 megabytes input standard input output standard output Shuseki
Kingdom
·
2015-11-07 10:41
c
HDU1025——LIS——Constructing Roads In JGShining's
Kingdom
Problem Description JGShining's
kingdom
consists of 2n(n is no more than 500,000) small cities which
·
2015-11-03 22:15
struct
United
Kingdom
- Google Zeitgeist 2008
It's been a big year for the Internet. From BBC's iPlayer to Facebook to YouTube, many of the top searches in Britain this year have been for our favourite websites. We also see three web-savvy politi
·
2015-11-02 19:32
Google
POJ 1904 King's Quest - from lanshui_Yang
And there were N beautiful girls in the
kingdom
and the king knew about each of his sons which of those
·
2015-11-02 15:14
poj
HDU 1025 (LIS+二分) Constructing Roads In JGShining's
Kingdom
这是最大上升子序列的变形,可并没有LIS那么简单。 需要用到二分查找来优化。 看了别人的代码,给人一种虽不明但觉厉的赶脚 直接复制粘贴了,嘿嘿 原文链接: http://blog.csdn.net/ice_crazy/article/details/7536332 假设存在一个序列d[1..9] = 2 1 5 3 6 4 8 9 7,可以看出来它的LIS长度为5
·
2015-11-02 11:44
struct
差分约束系统 ZQUOJ 21452&&POJ 1364 King
Description Once, in one
kingdom
, there was a queen and that queen was expecting a baby.
·
2015-11-02 09:56
差分约束
UVA 12507 Kingdoms
nbsp; Memory Limit:0KB 64bit IO Format:%lld & %llu A
kingdom
·
2015-11-01 15:57
dom
HDU1025:Constructing Roads In JGShining's
Kingdom
(LIS)
Problem Description JGShining's
kingdom
consists of 2n(n is no more than 500,000) small cities which
·
2015-11-01 13:13
struct
HDU 1025 Constructing Roads In JGShining's
Kingdom
(最长上升子序列的长度)
Constructing Roads In JGShining's
Kingdom
Time Limit: 2000/1000 MS (Java/Others)  
·
2015-11-01 12:29
struct
uva 11292 Dragon of Loowater (勇者斗恶龙)
Problem C: The Dragon of Loowater Once upon a time, in the
Kingdom
of Loowater, a minor nuisance turned
·
2015-11-01 12:00
water
Hdu 1025(LIS)
Constructing Roads In JGShining's
Kingdom
Time Limit: 2000/1000 MS (Java/Others)
·
2015-11-01 11:43
HDU
hdu 4081 Qin Shi Huang's National Road System 树的基本性质 or 次小生成树思想 难度:1
Ying Zheng was the king of the
kingdom
Qin.
·
2015-11-01 10:17
System
Uva 11292 The Dragon of Loowater(排序后贪心)
Problem C: The Dragon of Loowater Once upon a time, in the
Kingdom
of Loowater, a minor nuisance turned
·
2015-10-31 12:02
water
[ACM_水题] UVA 11292 Dragon of Loowater [勇士斗恶龙 双数组排序 贪心]
Once upon a time, in the
Kingdom
of Loowater, a minor nuisance turned into a major problem
·
2015-10-31 11:36
water
hdu 1025 Constructing Roads In JGShining's
Kingdom
本题明白题意以后,就可以看出是让求最长上升子序列,但是不知道最长上升子序列的算法,用了很多YY的方法去做,最后还是超时, 因为普通算法时间复杂度为O(n*2),去搜了题解,学习了一下,感觉不错,拿出来分享一下。 1 #include <stdio.h> 2 #include <string.h> 3 4 #define N 500005 5
·
2015-10-30 20:42
struct
上一页
1
2
3
4
5
6
7
下一页
按字母分类:
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
其他