[理工] 資結 Kruskal's algo

看板Grad-ProbAsk作者 (旋風噴射阿姆斯特朗砲)時間8年前 (2017/10/06 20:23), 8年前編輯推噓1(100)
留言1則, 1人參與, 8年前最新討論串1/1
林立宇老師課本中 下圖 (1)小題 http://i.imgur.com/RACuSSX.jpg
解答寫 Disjoint set ,是可以理解,因為的確要用 Disjoint set 確認加入新的邊是否 會形成 cycle 但要找最小權重邊不是也需要使用到 heap嗎? 煩請各位大大指點 ----- Sent from JPTT on my Sony C6902. -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 210.66.144.8 ※ 文章網址: https://www.ptt.cc/bbs/Grad-ProbAsk/M.1507292626.A.C7E.html

10/06 20:40, 8年前 , 1F
可以先排序就不用 heap 了吧
10/06 20:40, 1F
哦哦 懂了!感謝! ※ 編輯: box38431 (60.251.225.88), 10/06/2017 20:48:42 ※ 編輯: box38431 (210.66.144.8), 10/12/2017 12:19:09
文章代碼(AID): #1PrtNIn- (Grad-ProbAsk)