Single Source Shortest Path Using Dynamic Programming