Pregunta de entrevista de Travelzoo

Some basic math to figure out cost using their examples