Question d’entretien chez Amazon

Box packing algorithm question, complex