Kruskal’s algorithm for MST sorts edges by weight and adds them if they don’t form a cycle. What data structure efficiently supports the cycle-detection step ?
Asked in TPSC Junior System Engineer 2026
Answer under review: our editors are checking this question. Try the other TPSC Prelims previous year questions questions meanwhile.
More TPSC Prelims previous year questions questions
- Which asymptotic notation represents a tight bound — both upper and lower ?
- The Bellman-Ford algorithm detects negative weight cycles by
- In the Divide-and-Conquer approach, Strassen’s matrix multiplication reduces the number of recursive multiplications per 2×2 matrix from 8 to
- A problem is said to be NP-hard if :
- Which graph traversal algorithm is used to detect strongly connected components (SCCs) ?
- The Greedy algorithm for Activity Selection Problem works because the problem exhibits which property ?
- What is the time complexity of the Floyd-Warshall all-pairs shortest path algorithm ?
- In Ethernet (IEEE 802.3), the minimum frame size is 64 bytes. This is to ensure collision detection. If the propagation delay is t, the minimum frame transmission time must be at least