NeverOnTimeSdnBhd / Delivery-Instances

2 stars 6 forks source link

Question regarding BFS traversal #3

Open elgeneee opened 3 years ago

elgeneee commented 3 years ago

Hi NeverOnTimeSdnBhd,

As I am trying to solve the first part which is Basic Simulation and I used BFS to find the shortest route for each vehicle. Assuming that my BFS implementation is the traditional BFS that we learn in the lecture, starting from Customer 1 traverse to Customer 4, is it logical if I got the sequence as shown in the output below compare to your sample output?

Vehicle 1
0 -> 1 -> 3 -> 0
Capacity: 7
Cost: 124.53609229104421

Vehicle 2
0 -> 2 -> 0
Capacity: 8
Cost: 173.29743217947575

Vehicle 3
0 -> 4 -> 0
Capacity: 5
Cost: 48.41487374764082

I appreciate your time for reading this. Thank you! 🙏🏻

NeverOnTimeSdnBhd commented 3 years ago

Yes, Your answer is totally correct! 😄