 In this video, we provide the solution to question number four for practice exam number one for math 1030 And what is we're given here a weighted complete graph and we're asked to solve the traveling salesman problem on this graph Using the nearest neighbor algorithm starting at B. So that's what we're gonna do We're gonna start at B. We're gonna look at then who's the nearest neighbor to be so going to see would be 3.3 going to D would be 5.9 going to E would be 6.8 and going to a is 3.6 C is the short as the nearest neighbor right there. So we're gonna go to C next, okay? Then we're at C. We can go to a for 1.1 We could go to E for 3.5 or we could go to D for 5.3 1.1 is the nearest neighbor to C So we're gonna go there now be aware that we can't go back to be yet because that would make a premature circuit So we're just gonna remove that number from consideration So we don't accidentally be tempted by it because honestly 3.6 is the next cheapest one for a here So but we can't go back there can't go back to see so for a we have to either go to D for 5.6 Or we go to E for 4.5 4.5. We've been be the cheapest one there So we're gonna go to E now that we're at E. We can't go to B We can't go back there until the very very end. We can't go back to C yet either So we actually are forced to go to D at that moment D is gonna cost 5 Now that's the last vertex. We got to go back home So then we're gonna connect the dots here and that's our circuit So let's add these things together. We have a 3.3 plus 1.1 plus 4.5 plus 5.0 plus 5.9 Adding those together you end up with 19.8 and so we see that the correct answer is choice B