码迷,mamicode.com
首页 >  
搜索关键字:dragon balls    ( 484个结果
hdu 1199 Color the Ball 离散线段树
C - Color the Ball Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionThere are infinite balls in a line (num...
分类:其他好文   时间:2015-01-24 13:04:14    阅读次数:195
HDU-1902-The Dragon of Loowater
题目:hdu-1902-The Dragon of Loowater贪心,两遍排序。 1 #include 2 #include 3 #include 4 #include 5 #include 6 7 using namespace std; 8 9 int nn[20010],mm[200...
分类:其他好文   时间:2015-01-22 14:55:07    阅读次数:110
POJ 3687 Labeling Balls 逆向拓扑排序
链接: poj3687 题意: 有N个标号为1~N的小球,重量(不包括断言)依次增加 ,现给出M句断言 ,断言格式为a b 表示小球a轻于小球b     要求根据重量大小依次输出1~N号小球应在的的位置(重量递增)不满足断言则输出-1 题解: 因为重量是依次增加的  不能按常规的构造edge[a][b]=1生成拓扑排序 既然关系格式和一般拓扑排序是相反的 ...
分类:编程语言   时间:2015-01-22 13:28:22    阅读次数:204
Codeforces 148D Bag of mice(概率dp)
题目大意: 黑箱子里有w只白老鼠和b只黑老鼠,dragon和Princess轮流从箱子中拿出一只老鼠,先取到白老鼠的人赢,但是dragon每次拿的时候都会多跑出一只老鼠。 思路分析: dp[i][j] 表示箱子里有i只白老鼠和j只黑老鼠的时候 Princess 先取赢的概率。 那么转移方程就有4个。 分别是 : 直接取到白老鼠 取到黑老鼠,dragon也拿到了黑老鼠,跑了一只...
分类:其他好文   时间:2015-01-19 15:49:32    阅读次数:185
heartbeat搭建高可用NFS
基本环境准备;[root@localhost~]#vim/etc/sysconfig/network(修改主机名)NETWORKING=yesHOSTNAME=node1.dragon.com(这里每台主机自行修改为node1,2,3)[root@localhost~]#vim/etc/hosts(修改主机文件,分别指向node1,2,3)127.0.0.1localhostlocalhost.localdomainlocalho..
分类:其他好文   时间:2015-01-19 06:59:25    阅读次数:401
POJ 3687-Labeling Balls(逆序拓扑排序)
Labeling Balls Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 11256   Accepted: 3230 Description Windy has N balls of distinct weights from 1 unit to N un...
分类:编程语言   时间:2015-01-12 09:26:20    阅读次数:266
基本概率分布Basic Concept of Probability Distributions 5: Hypergemometric Distribution
PDF versionPMFSuppose that a sample of size $n$ is to be chosen randomly (without replacement) from an urn containing $N$ balls, of which $m$ are whit...
分类:其他好文   时间:2015-01-06 19:47:28    阅读次数:225
poj 3646 The Dragon of Loowater 排序+贪心
水题,直接贴代码。 //poj 3646 //sep9 #include #include using namespace std; const int maxN=20012; int a[maxN],b[maxN]; int main() { int n,m; while(scanf("%d%d",&n,&m)==2&&n+m){ int i,j; for(i=0;i<n;+...
分类:编程语言   时间:2014-12-30 00:33:09    阅读次数:233
HDU 3874 Necklace(树状数组)
Problem Description Mery has a beautiful necklace. The necklace is made up of N magic balls. Each ball has a beautiful value. The balls with the same beautiful value look the same, so if two or mor...
分类:编程语言   时间:2014-12-29 01:05:55    阅读次数:209
A - Dragon of Loowater
Problem C: The Dragon of LoowaterOnce upon a time, in the Kingdom of Loowater, a minor nuisance turned into a major problem.The shores of Rellau Creek...
分类:其他好文   时间:2014-12-15 18:50:08    阅读次数:323
484条   上一页 1 ... 36 37 38 39 40 ... 49 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!