Pregunta de entrevista de United Airlines

How would you solve this problem?