Q.insert(s,0) while not Q.isEmpty() do v ← Q.dequeue() if v = t then. // shortest path found return end forall outgoing edges e = (v,w) do.
確定! 回上一頁