guess the next step: Dijkstra's shortest paths
Before each step plays, guess what it does. The page then shows the step as the run takes it and says why, the same sentence the watch page says there.
Step 7 of 19
Question 7 of 17
Step 7 of 19
Step 8 of 19
Step 9 of 19
Step 10 of 19
Step 11 of 19
Step 12 of 19
Step 13 of 19
Question 7 of 17
Question 7 of 17
Not this time.
You guessed: Through F, the way to B is shorter than any found before, so write it.
What the run did:
The road from F to B is 3 long, so through F it is 7 to B, no shorter than the 7 written there. Keep 7.
Question 7 of 17
Right.
You guessed: Through F, the way to B is no shorter, so keep what is written.
What the run did:
The road from F to B is 3 long, so through F it is 7 to B, no shorter than the 7 written there. Keep 7.
Question 8 of 17
Question 8 of 17
Right.
You guessed: Through F, the way to G is shorter than any found before, so write it.
What the run did:
The road from F to G is 3 long, so through F it is 7 to G, shorter than any way found before. Write 7 at G.
Question 8 of 17
Not this time.
You guessed: Through F, the way to G is no shorter, so keep what is written.
What the run did:
The road from F to G is 3 long, so through F it is 7 to G, shorter than any way found before. Write 7 at G.
Question 9 of 17
Question 9 of 17
Not this time.
You guessed: The nearest place not settled yet is 5 away.
What the run did:
Of the places with a distance and not settled yet, B is the nearest, at 7. Settle it: any other way to B would go through a place at least as far away.
Question 9 of 17
Not this time.
You guessed: The nearest place not settled yet is 6 away.
What the run did:
Of the places with a distance and not settled yet, B is the nearest, at 7. Settle it: any other way to B would go through a place at least as far away.
Question 9 of 17
Right.
You guessed: The nearest place not settled yet is 7 away.
What the run did:
Of the places with a distance and not settled yet, B is the nearest, at 7. Settle it: any other way to B would go through a place at least as far away.
Question 10 of 17
Question 10 of 17
Right.
You guessed: Through B, the way to C is shorter than any found before, so write it.
What the run did:
The road from B to C is 7 long, so through B it is 14 to C, shorter than any way found before. Write 14 at C.
Question 10 of 17
Not this time.
You guessed: Through B, the way to C is no shorter, so keep what is written.
What the run did:
The road from B to C is 7 long, so through B it is 14 to C, shorter than any way found before. Write 14 at C.
Question 11 of 17
Question 11 of 17
Not this time.
You guessed: The nearest place not settled yet is 6 away.
What the run did:
Of the places with a distance and not settled yet, G is the nearest, at 7. Settle it: any other way to G would go through a place at least as far away.
Question 11 of 17
Right.
You guessed: The nearest place not settled yet is 7 away.
What the run did:
Of the places with a distance and not settled yet, G is the nearest, at 7. Settle it: any other way to G would go through a place at least as far away.
Question 11 of 17
Not this time.
You guessed: The nearest place not settled yet is 8 away.
What the run did:
Of the places with a distance and not settled yet, G is the nearest, at 7. Settle it: any other way to G would go through a place at least as far away.
Question 12 of 17
Question 12 of 17
Right.
You guessed: Through G, the way to C is shorter than any found before, so write it.
What the run did:
The road from G to C is 2 long, so through G it is 9 to C, shorter than any way found before. Write 9 at C.
Question 12 of 17
Not this time.
You guessed: Through G, the way to C is no shorter, so keep what is written.
What the run did:
The road from G to C is 2 long, so through G it is 9 to C, shorter than any way found before. Write 9 at C.