- A graph G has the property that removing any single edge results in exactly two connected components, each of which is a tree. How many spanning trees does G have?
Answer: Graph G has exactly 1 spanning tree, since G itself must be a tree
Read the condition carefully: removing any single edge leaves exactly two connected components. That means G is connected to begin with, and every edge is a bridge.
An edge lies on a cycle exactly when it is not a bridge, because removing a cycle edge leaves the graph connected through the rest of the cycle. Since every edge of G is a bridge, G has no cycles. A connected graph with no cycles is a tree, so G is a tree, and the only spanning tree of a tree is the tree itself. G has exactly 1 spanning tree.
A graph with one cycle of length k has k spanning trees, but it fails the condition, since removing a cycle edge leaves one component, not two. The same objection rules out a tree with one extra edge and any count of 2 or n−1: each requires a cycle. - A minimum spanning tree of a weighted graph G has total weight W. If all edge weights in G are increased by a constant c>0, what can be concluded about the new minimum spanning tree?
Answer: The new MST will have the same structure as the original, with total weight W+c(n−1) where n is the number of vertices
Adding a constant c to all edge weights preserves the relative ordering of edges, so the same MST structure is optimal. Since an MST has exactly n-1 edges (where n is the number of vertices), the total weight increases by c(n-1). Choice A incorrectly adds c only once instead of c times the number of MST edges. Choice C correctly calculates weight but wrongly suggests structure might change. Choice D uses the wrong multiplier (total edges instead of MST edges) and suggests structure might change. - Consider the following modification to Kruskal's algorithm: instead of always choosing the minimum weight edge that doesn't create a cycle, we choose the minimum weight edge that doesn't create a cycle AND has at least one endpoint with degree less than 3 in the current forest. If this modified algorithm produces a spanning tree, what can be concluded about the final tree?
Answer: The resulting spanning tree has total weight greater than or equal to the minimum spanning tree, but its maximum degree can exceed 3
The rule only requires at least one endpoint of the chosen edge to have degree less than 3. If a vertex u already has degree 3 and its neighbor v has degree 0, the edge uv is still allowed, so u can reach degree 4 or more. The degree of the tree is therefore not capped at 3.
The weight claim does hold: the output is a spanning tree, and no spanning tree weighs less than a minimum spanning tree, so its weight is at least the MST weight.
The claim that the tree is identical to the MST fails because the restriction can force the algorithm to skip a lighter edge. A tree lighter than the MST is impossible by definition, and nothing forces exactly three vertices of degree 3, or a maximum degree of exactly 3. - A spanning tree T of graph G has the property that adding any edge from G that is not in T creates exactly one cycle. If G has 15 vertices and 22 edges, how many edges are not in T?
Answer: There are 8 edges in G that are not included in spanning tree T
When you encounter spanning tree problems, focus on the fundamental property: a spanning tree of a graph with n vertices always contains exactly n−1 edges, regardless of how many edges the original graph has.
Since graph G has 15 vertices, any spanning tree T must contain exactly 15−1=14 edges. This is because a spanning tree connects all vertices with the minimum number of edges needed to avoid cycles. Given that G has 22 total edges, the number of edges not in T is 22−14=8 edges.
The property mentioned in the problem—that adding any excluded edge creates exactly one cycle—confirms this is indeed a valid spanning tree, but doesn't change the edge count calculation.
Looking at the wrong answers: Answer A suggests 7 missing edges, which would mean the spanning tree has 15 edges (creating a cycle). Answer B suggests 6 missing edges, implying 16 edges in the tree (multiple cycles). Answer D suggests 9 missing edges, meaning only 13 edges in the tree (leaving vertices disconnected, so not spanning).
Answer C correctly identifies 8 edges not in T.
Study tip: Memorize the spanning tree formula: for any connected graph with n vertices, every spanning tree has exactly n−1 edges. This makes spanning tree problems straightforward—just subtract (n−1) from the total edge count to find excluded edges. - Consider a connected graph where every edge has a distinct weight. If edge e is the heaviest edge in some cycle C, what can be concluded about e's inclusion in the minimum spanning tree?
Answer: Edge e cannot be included in any minimum spanning tree of the graph
This follows from the cycle property of MSTs: if e is the heaviest edge in cycle C, then e cannot be in any MST. This is because we could remove e and add any other edge from C to get a spanning tree with smaller total weight. The distinctness of weights ensures this conclusion is definitive. Choice B is wrong because edges outside C don't affect this property. Choice C is wrong because being the global heaviest isn't necessary. Choice D confuses the cycle property with bridge characterization. - In Prim's algorithm starting from vertex s, the edges are added to the spanning tree in the order: (s,a) weight 3, (a,b) weight 5, (b,d) weight 4, (s,c) weight 6, (c,e) weight 7. All edge weights in the graph are distinct. What is the minimum possible weight of edge (a,c) in the original graph?
Answer: The edge (a,c) must have weight greater than 6, otherwise it would have been selected instead of (s,c)
Prim's algorithm always adds the lightest edge joining the tree to a vertex outside it. After (s,a), (a,b) and (b,d) are added, the tree is {s,a,b,d}, and both (s,c) and (a,c) cross from the tree to c. The algorithm chose (s,c) with weight 6, so with distinct weights (a,c) must weigh more than 6. A bound of more than 5 only explains why (a,b) was chosen first and is too weak. Requiring at least 7 confuses the comparison with (c,e); by then c is in the tree and (a,c) is no longer a candidate, so a weight such as 6.5 is possible. Saying any weight above 5 works ignores that (a,c) was competing with (s,c). - In a minimum spanning tree algorithm, the cut property states that for any cut of the graph, the minimum weight edge crossing the cut is guaranteed to be in some MST. However, this edge might not be in every MST when there are multiple MSTs. Under what condition is the minimum weight edge crossing a cut guaranteed to be in every MST?
Answer: When the minimum weight edge crossing the cut has weight strictly less than all other edges crossing that same cut
When analyzing minimum spanning trees (MSTs), you need to understand the distinction between "some MST" and "every MST." The cut property guarantees that the minimum weight edge crossing any cut appears in at least one MST, but when multiple edges share the same minimum weight across a cut, different MSTs might include different edges.
The key insight is uniqueness. When the minimum weight edge crossing a cut has weight strictly less than all other edges crossing that same cut, there's no ambiguity—this edge is the only choice for connecting the two sides of the cut with minimum cost. Since every MST must connect these components and must do so optimally, every MST must include this unique minimum edge.
Option A is wrong because vertex degree and cut size don't determine edge uniqueness across the cut. Option B incorrectly focuses on component sizes, which are irrelevant to edge weight uniqueness. Option C seems tempting, but being the global minimum edge doesn't guarantee uniqueness across a specific cut—there could still be multiple edges with the same global minimum weight crossing that cut.
Option D correctly identifies that strict inequality (the edge weighs less than all others crossing the cut) ensures uniqueness. When there's only one minimum weight edge crossing a cut, every MST algorithm must select it.
Study tip: In MST problems, always ask whether edges are unique. When weights are tied, multiple valid choices exist. When one edge is strictly better, it becomes mandatory in every optimal solution.
- In Prim's algorithm, at each step we select the minimum weight edge that connects the current tree to a vertex not yet in the tree. If there are multiple edges with the same minimum weight, the choice among them affects which property of the final result?
Answer: The choice affects the structure but not the total weight of the resulting spanning tree
When there are ties in edge weights during Prim's algorithm, different choices lead to different spanning tree structures, but the total weight remains the same because we're always selecting from edges with identical minimum weights at each step. This is a fundamental property of MST algorithms when ties exist. Choice A wrongly suggests weight changes. Choice C reverses the correct relationship. Choice D wrongly suggests no effect on structure.
- A connected graph G has n vertices and m edges where m>n. After running Kruskal's algorithm, suppose exactly k edges were rejected because they would have created cycles. What is the relationship between k, m, and n?
Answer: The number of rejected edges satisfies k=m−n+1, representing excess edges beyond tree requirement
When you encounter questions about minimum spanning trees and Kruskal's algorithm, focus on the fundamental relationship between edges in trees versus general graphs. A tree with n vertices always has exactly n−1 edges—this is a core property that connects to cycle detection.
Kruskal's algorithm builds a minimum spanning tree by adding edges in order of increasing weight, rejecting any edge that would create a cycle. Since the final spanning tree must have exactly n−1 edges and the original graph has m edges, the algorithm accepts n−1 edges and rejects m−(n−1)=m−n+1 edges. This gives us k=m−n+1, confirming answer D.
Let's examine why the other options fail. Option A gives k=n−m+1, which would be negative since m>n—but you can't reject a negative number of edges. Option B suggests k=m−n, which undercounts the rejected edges by 1, missing that trees need n−1 edges, not n edges. Option C proposes k=m−n−1, which undercounts by 2, perhaps confusing the tree property or double-subtracting somewhere in the reasoning.
The key insight is recognizing that "excess edges beyond tree requirement" means edges beyond the n−1 needed for a spanning tree. Since we start with m edges and need n−1, we reject m−(n−1)=m−n+1 edges.
Study tip: Memorize that any tree on n vertices has exactly n−1 edges. This relationship appears frequently in spanning tree, cycle detection, and connectivity problems. - In Kruskal's algorithm applied to a weighted graph, edges are considered in the order: (u1,v1) weight 2, (u2,v2) weight 3, (u3,v3) weight 3, (u4,v4) weight 4, (u5,v5) weight 5. If the algorithm accepts the first, second, and fourth edges but rejects the third and fifth edges, what can be concluded about the graph structure?
Answer: The third edge creates a cycle with the first two edges, and the fourth edge connects previously separate components
Kruskal's algorithm rejects an edge exactly when its endpoints are already in the same component, because adding it would form a cycle; an edge is never rejected for its weight. After the first two edges are accepted, the third edge is rejected, so its endpoints are already joined by the first two edges. In a simple graph that connecting path must use both of them, so the third edge closes a cycle with the first two. The fourth edge is accepted, so it joined two previously separate components. The third edge's weight (3) equals the second edge's weight, so weight cannot explain its rejection. Only three edges were accepted, and nothing shows the graph has exactly 4 vertices or that the tree was complete; the rejected fifth edge only shows its endpoints were already connected.
- In a weighted graph, Prim's algorithm is being executed starting from vertex v. After k iterations, the algorithm has selected a set S of edges. Which statement about S is always true?
Answer: S contains k edges that form a tree connecting k+1 vertices including v
Prim's algorithm maintains a tree at each step, adding exactly one vertex per iteration. After k iterations, we have k edges connecting k+1 vertices (including the starting vertex v). Choice A is wrong because Prim's doesn't necessarily select globally lightest edges, only lightest edges crossing the current cut. Choice B is wrong because S represents the MST of the vertices selected so far, not of some induced subgraph. Choice D is wrong because not every lightest cut edge is included, only those that extend the current tree. - Consider applying Kruskal's algorithm to find a minimum spanning tree. At some intermediate step, we have already selected edges with weights {2,3,5,7,8} and the next edges available (in order of increasing weight) are {9,10,11,12}. If selecting the edge of weight 9 would create a cycle, which statement is necessarily true?
Answer: At least one edge from {10,11,12} must be examined before completion
Since 5 edges are selected and one more (weight 9) creates a cycle, we have at least 6 vertices. A spanning tree needs n-1 edges for n vertices, so we need at least 1 more edge. Since weight 9 is rejected, we must examine subsequent edges. Choice A is wrong because weight 10 might also create cycles. Choice C assumes exactly 6 vertices but we could have more. Choice D is wrong because we might need more than 2 additional edges if we have more than 7 vertices total. - A graph has vertices {A,B,C,D,E} with edge weights as follows: AB=4, AC=2, AD=7, BC=3, BD=6, CD=1, CE=5, DE=8. When finding the MST using Kruskal's algorithm, which edge is selected third?
Answer: Edge BC with weight 3 is selected as the third edge in the algorithm
Kruskal's algorithm sorts edges by weight: CD(1), AC(2), BC(3), AB(4), CE(5), BD(6), AD(7), DE(8). First iteration: select CD(1). Second iteration: select AC(2). Third iteration: BC(3) doesn't create a cycle with {CD, AC} since it connects B to the existing component {A,C,D}. Choice B is wrong because AB would be fourth. Choice C is wrong because AC is selected second, not third. Choice D is wrong because CE comes later in the sorted order. - A minimum spanning tree algorithm is run on a connected graph with distinct edge weights. The algorithm produces a spanning tree T with total weight 45. If the heaviest edge in T has weight 12, what can be definitively concluded?
Answer: There exists no spanning tree of this graph with total weight less than 45
Tree T is a minimum spanning tree, so by definition no spanning tree weighs less than 45. With distinct edge weights the MST is also unique, so every other spanning tree weighs more than 45. An MST also minimizes the heaviest edge: every spanning tree must have a heaviest edge of at least 12. That makes the claim that other spanning trees have a heaviest edge below 12 false. The claim that every spanning tree weighs 45 is false, since other trees weigh more. The claim that every spanning tree contains the weight-12 edge is false: a different tree can use a heavier edge to connect the same two parts of the graph. - Consider running Kruskal's algorithm on a graph where some edges have equal weights. During execution, we encounter a situation where three edges e1,e2,e3 all have weight w and are the next candidates for selection. If selecting any two of these three edges would complete the MST, what must be true about the graph structure at this point?
Answer: The graph currently has exactly 3 connected components, and edges e1,e2,e3 each connect different pairs of these components
If selecting any two of three edges completes the MST, we need exactly 2 more edges to finish. This means we currently have exactly 3 components (since each edge reduces components by 1, and 3→2→1 requires 2 edges). The three edges must connect different pairs among these 3 components, and any 2 selections will connect all components. Choice B has wrong component count. Choice C would require 3 edges to connect 4 components. Choice D has incorrect component arithmetic.