Shortest Path Algorithm

X is your starting point:

  1. Place <X, [], 0> on READY.

  2. Pick <N,P,L> on READY with minimum L.

  3. Repeat step 2 until READY is empty.