Thoughtworks interview question

Convoluted lists