Epitec interview question

Coding challenge on the first interview, one week assignment on the second.