diff --git a/prose/17_graphs1.md b/prose/17_graphs1.md index 56aeedc..784af70 100644 --- a/prose/17_graphs1.md +++ b/prose/17_graphs1.md @@ -238,7 +238,7 @@ print("[1,2,3,1] is a path", G.ispath([1,2,3,1])) print("[1,2,3,1] is a simple path", G.issimplepath([1,2,3,1])) print("[1,2,3] is a simple path", G.issimplepath([1,2,3])) print("[1,2,3] is a simple cycle:", G.issimplecycle([1,2,3])) -print("[1,2,3,1] is a simple cycle:", G.issimplecycle([1,2,3])) +print("[1,2,3,1] is a simple cycle:", G.issimplecycle([1,2,3,1])) print("[1,2,3,4] is a simple path:", G.issimplepath([1,2,3,4])) print("[1,2,3,4] is a simple cycle:", G.issimplecycle([1,2,3,4])) print("[1,2,3,4,3,1] is a cycle:", G.iscycle([1,2,3,4,3,1])) diff --git a/prose/18_graphs2.md b/prose/18_graphs2.md index 30ede04..79756d8 100644 --- a/prose/18_graphs2.md +++ b/prose/18_graphs2.md @@ -324,7 +324,7 @@ In that case, we first tried to write a function that would test for correct out We won't go that far now, but we will ask, "How would we know if we had the minimum spanning tree?" One thing that would certainly be true about the minimum spanning tree is that if we removed an edge (resulting in two trees), we couldn't find a lighter weight edge connecting these two trees. -Otehrwise, that would be a spanning tree of lower weight. +Otherwise, that would be a spanning tree of lower weight. Something even a little more general is true. If we split the vertices into any two sets $A$ and $B$, the lowest weight edge with one end in $A$ and the other end in $B$ must be in the MST.