Pergunta de entrevista da empresa GEP

solve logical question for heavy ball in total 8 balls using weighing machine