Q. Prim’s algorithm can be efficiently implemented using for graphs with greater density.

  • (A) d-ary heap
  • (B) linear search
  • (C) fibonacci heap
  • (D) binary search
πŸ’¬ Discuss
βœ… Correct Answer: (A) d-ary heap
Explanation: in prim’s algorithm, we add the minimum weight edge for the chosen vertex which requires searching on the array of weights. this searching can be efficiently implemented using binary heap for dense graphs. and for graphs with greater density, prim’s algorithm can be made to run in linear time using d-ary heap(generalization of binary heap).

Explanation by: Mr. Dubey
in prim’s algorithm, we add the minimum weight edge for the chosen vertex which requires searching on the array of weights. this searching can be efficiently implemented using binary heap for dense graphs. and for graphs with greater density, prim’s algorithm can be made to run in linear time using d-ary heap(generalization of binary heap).

πŸ’¬ Discussion

πŸ“Š Question Analytics

πŸ‘οΈ
519
Total Visits
πŸ“½οΈ
3 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
81%
Success Rate