Domanda di colloquio di Microsoft

How would you code in less time this ...?