Decisionand optimizationproblemsinvolvinggraphsarise in manyareas of artificial intelligence, including probabilistic networks, robot navigation, and network design. Manysuch problemsare NP-complete;this has necessitated the developmentof approximationmethods, most of which are very complex and highly problemspecific. Weproposea straightforward,practical approach to algorithm design based on MarkovChainMonteCarlo (MCMC),a statistical simulation schemefor efficiently samplingfroma large (possiblyexponential)set, suchas the set of feasible solutions to a combinatorialtask. This facilitates the developmentof simple,efficient, andgeneral solutionsto wholeclasses of decisionproblems.Weprovide detailed examplesshowinghowthis approachcan be used for spanning tree problemssuch as Degree-Constrained SpanningTree, MaximumLeaf SpanningTree, and Kth Best SpanningTree.