Linearity GmbH interview question

Dealing with the technical test