Tarjan
mowayao
这个作者很懒,什么都没留下…
展开
-
UVa11324 - The Largest Clique(DAG+DP+SCC)
Problem B: The Largest Clique Given a directed graph G, consider the following transformation. First, create a new graph T(G) to have the same vertex set as G. Create a directed edge between two ve原创 2014-08-05 17:19:34 · 622 阅读 · 0 评论 -
POJ3352-Road Construction
Road Construction Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 8652 Accepted: 4323 Description It's almost summer time, and that means that it's almost原创 2014-08-05 20:49:18 · 505 阅读 · 0 评论 -
POJ2723-Get Luffy Out(2-SAT)
Get Luffy Out Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 7456 Accepted: 2835 Description Ratish is a young man who always dreams of being a hero. One原创 2014-08-07 18:43:04 · 735 阅读 · 0 评论 -
POJ3207-Ikki's Story IV - Panda's Trick(2-SAT)
Ikki's Story IV - Panda's Trick Time Limit: 1000MS Memory Limit: 131072K Total Submissions: 7841 Accepted: 2900 Description liympanda, one of Ikki’s friend, likes p原创 2014-08-07 15:52:30 · 632 阅读 · 0 评论 -
POJ2762-Going from u to v or from v to u?(Tarjan缩点,DAG判直链)
Going from u to v or from v to u? Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 14474 Accepted: 3804 Description In order to make their sons brave, Jiaji原创 2014-08-15 13:37:09 · 565 阅读 · 0 评论 -
UVa 12587 Reduce the Maintenance Cost(Tarjan + 二分 + DFS)
题意:n个城市(n 思路:首先边的费用可以通过Tarjan求桥之后求得(利用桥的性质),然后就是二分答案了!对于每个点,如果有个儿子不能维护,那么不可行,否则,试着让儿子去维护边权,如果不可行,只能让父亲承担。 #include #include #include #include #include #include #include #include #include u原创 2014-10-12 12:30:43 · 846 阅读 · 0 评论