Here is the drive method. We increment the location and now we want to remove all passengers who wanted to get to that location. That turns out to be a bit tricky so I’ll want to find the passenger and then remove it. To remove a passenger I need to know the index. So I have an index i starts at zero, up to but not including the passenger size. I kept the i passenger, I test whether the destination of that person equals to current location and then I remove it. That’s all fine, but there’s something that one needs to be very careful about and that is when you remove the passenger you can’t increment the index. Here’s what I mean. Here are my passengers and let’s say i is 1 and now Jane has reached the destination, she gets removed then of course Mary now ends up in place one and then I need to come back to the loop with i staying at 1 so that I can examine whether Mary should also, leave the car. So that’s why there’re two branches here. In this branch, I removed the passenger, and in the other branch, I increment i, to get to see the next one. Now the car, and the person class, have most of the functionality that I need, but somewhere I still need to put the entire simulation together.