码迷,mamicode.com
首页 >  
搜索关键字:moral graph    ( 3648个结果
zabbix 基础概念
zabbix配置流程 Hostgroups(主机粗)-hosts(主机)Applications(监控项组)-items(监控项)-tiggers(触发器)-event(事件)-actions(处理动作)-usergroups(用户组)-users(用户)-medias(告警方式)-audit(日志审计) 一般items,tiggers,graph通常采用模板进行监..
分类:其他好文   时间:2015-09-21 12:30:38    阅读次数:245
深度优先算法DFS
深度优先算法的Java实现public class JavaDFS { public int stepnum = 999; /*构建11*11的迷宫,英雄H在(1,1)的位置出发,去解救美女M(6,8),#表示墙壁,*表示炸弹*/ public char[][] graph = {...
分类:编程语言   时间:2015-09-20 06:54:25    阅读次数:258
hdu 5452 Minimum Cut 树形dp
Minimum CutTime Limit: 1 Sec Memory Limit: 256 MB题目连接http://acm.hdu.edu.cn/showproblem.php?pid=5452DescriptionGiven a simple unweighted graph G (an un...
分类:其他好文   时间:2015-09-20 00:14:27    阅读次数:317
SPOJ Play on Words
传送门WORDS1 - Play on Words#graph-theory#euler-circuitSome of the secret doors contain avery interesting word puzzle. The team of archaeologists has to ...
分类:其他好文   时间:2015-09-18 21:42:13    阅读次数:210
hdu 3478 Catch(染色 dfs 或 bfs )
Problem DescriptionA thief is running away!We can consider the city where he locates as an undirected graph in which nodes stand for crosses and edges...
分类:其他好文   时间:2015-09-18 18:00:26    阅读次数:203
codeforces 295B B. Greg and Graph(floyd+dp)
题目链接:codeforces 295B题目大意:给出n个点的完全有权有向图,每次删去一个点,求每次操作前整张图各个点的最短路之和。题目分析: 首先删边对于我们来说是不好做的,所以我们想到了通过加点的方式逆向地做,那么加点怎么做呢? 其实就是一个我们很熟悉的算法:floyd,因为我们通常用的都是它的简化版本,所以可能很多人并不理解它的确切的思想。 在介绍这道题的具体解法之前,我先解释一下floyd,...
分类:其他好文   时间:2015-09-18 13:56:44    阅读次数:169
poj 3678 Katu Puzzle(2-sat)
DescriptionKatu Puzzle is presented as a directed graph G(V, E) with each edge e(a, b) labeled by a boolean operator op (one of AND, OR, XOR) and an i...
分类:其他好文   时间:2015-09-16 20:06:42    阅读次数:162
codeforces 340D D. Bubble Sort Graph(dp+线段树)
题目链接:codeforces 340D题目大意:给出一个程序,就是冒泡排序,每次如果发现相邻两个数前一个大于后一个,交换位置后建边,问最后得到的这个图中的最大独立集,这个最大独立集定义为所有的点都不相邻的最大点的集合的规模。题目分析: 首先我们可以知道对于a[i],它只会且一定会与后面的比它小的建边,所以我们只需要固定第一个点,然后找最长上升子序列即可。(这样能够保证没有相邻的点) 定义状态dp[...
分类:其他好文   时间:2015-09-15 18:34:42    阅读次数:207
UVALive 5031 Graph and Queries (Treap)
删除边的操作不容易实现一般就是先离线然后逆序来做。逆序就变成了合并,用并存集判断连通,用Treap树来维护一个连通分量里的名次。Treap = Tree + Heap。就是用一个随机的优先级来平衡树。名次查询需要维护树的结点数量,假设当前在u点,u的左子树有n个结点,那么u的就是以u为根的树上第n+...
分类:其他好文   时间:2015-09-13 18:40:42    阅读次数:221
[LeetCode#261] Graph Valid Tree
Problem:Givennnodes labeled from0ton - 1and a list of undirected edges (each edge is a pair of nodes), write a function to check whether these edges m...
分类:其他好文   时间:2015-09-12 06:21:54    阅读次数:428
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!