My first experience with this game was actually during an interview. About halfway through I found the bug. The below code snippet will successfully solve all of the challenges.
{
init: function(elevators, floors) {
world.transportedCounter = 500
},
update: function(dt, elevators, floors) {
// We normally don't need to do anything here
}
}