Graph Theory - Kruskal Algorithm [Disjoint Set] (Arabic)

  Рет қаралды 14,145

Arabic Competitive Programming

Arabic Competitive Programming

Күн бұрын

Content:
Kruskal Algorithm
Disjoint-set data structure
Second MST
Partial MST
Kruskal Variation for minimax path
Count # of spanning trees
Count # of MSTs
Problems: UVA(10034, 10147, 10369, 10397, 10462, 10600, 10842, 10766, 459, 793, 10608, 10685, 11503), SPOJ(MSTS)

Пікірлер: 21
@Donbcheap
@Donbcheap 11 ай бұрын
I understood this more than Prim Algorithm
@Miller4way
@Miller4way 10 жыл бұрын
Just brilliant , Thx , but you have forgotten to upload this session to ur dropbox :D
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 10 жыл бұрын
I lost it :(
@mohamednabil9146
@mohamednabil9146 7 жыл бұрын
Sir, Minimax was in Flloyd if I remember correctly, not Dijkstra right ?
@Donbcheap
@Donbcheap 11 ай бұрын
وعليكم السلام ورحمة الله وبركاته
@ayasaber2567
@ayasaber2567 9 жыл бұрын
ربنا يجزاكيك كل خير , ممكن الاكواد ؟؟
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 9 жыл бұрын
I lost it :( You have to write it
@amrmaghraby327
@amrmaghraby327 8 жыл бұрын
But why when i am solving on Disjoint only i must to decrement x and y before enter UNION_SET function and when i use Miniumm spanning tree i mustn't decrement it??????
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 8 жыл бұрын
I am not sure what seanrio you faced. Try to solve more problems. x and y are zero based positions in both Dijstra and other problems.
@amrmaghraby327
@amrmaghraby327 8 жыл бұрын
yes that what i was convinced with when solving disjoint but when i wrote MST it got WA and after removing decrementing it got AC
@amrmaghraby327
@amrmaghraby327 8 жыл бұрын
I was following this Scenario at line 72 and 73 tausiq.wordpress.com/2013/05/30/minimum-spanning-tree-kruskal-algorithm-source-code-cc/
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 8 жыл бұрын
show your wrong code in some solving facebook groups and ask them why decrementing is WA probably it was already 0 based
@visheshmaheshwari2663
@visheshmaheshwari2663 4 жыл бұрын
Can you please send the code for counting number of MSTs in a graph I cannot understand it from visuals and i don't speak arabic. Thanks.
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 4 жыл бұрын
github.com/mostafa-saad/MyCompetitiveProgramming/blob/master/SPOJ/SPOJ_MSTS.txt
@MohammedAli-xt9dy
@MohammedAli-xt9dy 8 жыл бұрын
???more detail second minimum spanning tree
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 8 жыл бұрын
there is a UVA problem about it...try to solve it...or see forums for solution idea is normal...you can get it by yourself
@MohammedAli-xt9dy
@MohammedAli-xt9dy 8 жыл бұрын
thanks
@MohammedAli-xt9dy
@MohammedAli-xt9dy 8 жыл бұрын
الكود ده صح لان اجيب second minimum spanning tree
@MohammedAli-xt9dy
@MohammedAli-xt9dy 8 жыл бұрын
ideone.com/FN0WRL
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 8 жыл бұрын
try it on a problem and see
@m00oon
@m00oon 5 жыл бұрын
sir , can you please speak in english
Graph Theory - Dijkstra Algorithm (Arabic)
21:17
Arabic Competitive Programming
Рет қаралды 22 М.
3.5 Prims and Kruskals Algorithms - Greedy Method
20:12
Abdul Bari
Рет қаралды 2,8 МЛН
Worst flight ever
00:55
Adam W
Рет қаралды 31 МЛН
Please Help This Poor Boy 🙏
00:40
Alan Chikin Chow
Рет қаралды 23 МЛН
Will A Guitar Boat Hold My Weight?
00:20
MrBeast
Рет қаралды 265 МЛН
Union Find Kruskal's Algorithm
6:15
WilliamFiset
Рет қаралды 204 М.
Eager Prim's Minimum Spanning Tree Algorithm | Graph Theory
14:33
WilliamFiset
Рет қаралды 25 М.
Data Structures - Segment Tree - 1 (Arabic)
31:24
Arabic Competitive Programming
Рет қаралды 13 М.
Graph Theory - Maximum Flow - 1 (Arabic)
22:10
Arabic Competitive Programming
Рет қаралды 16 М.
Graph Theory - Prim Algorithm (Arabic)
19:17
Arabic Competitive Programming
Рет қаралды 17 М.
Search Techniques - Binary Search (Arabic)
22:00
Arabic Competitive Programming
Рет қаралды 41 М.
Introduction to Graph Theory: A Computer Science Perspective
16:26
Graph Theory - BFS (Arabic)
15:43
Arabic Competitive Programming
Рет қаралды 30 М.
Max Flow Ford Fulkerson | Network Flow | Graph Theory
13:25
WilliamFiset
Рет қаралды 466 М.
Worst flight ever
00:55
Adam W
Рет қаралды 31 МЛН